┌   ┐
54
└   ┘

summaryrefslogtreecommitdiff
path: root/src/dolphinmainwindow.h
diff options
context:
space:
mode:
authorPeter Penz <[email protected]>2011-10-08 21:40:34 +0200
committerPeter Penz <[email protected]>2011-10-08 21:43:55 +0200
commit6551c000fc68134932cdc21f2cc7086b34bff30b (patch)
treef4892d247c13f988ee68de37ea1700aaf6e80ab2 /src/dolphinmainwindow.h
parentb1b5a6db2e8b9b1fc175d068ba393925d95c9dc6 (diff)
Context menu cleanups
- Open the context menu on the mouse-press event, not on the mouse-release event. - Provide an explicit position-information and don't use QCursor::pos(). This fixes the issue that opening a context-menu by the keyboard opens below the cursor. - Provide different signals in the KItemListController for the different context-menu types (item vs. view vs. header). - Implement turning on/off roles by the header-context-menu.
Diffstat (limited to 'src/dolphinmainwindow.h')
-rw-r--r--src/dolphinmainwindow.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/dolphinmainwindow.h b/src/dolphinmainwindow.h
index 9fb83bfa0..6736e24aa 100644
--- a/src/dolphinmainwindow.h
+++ b/src/dolphinmainwindow.h
@@ -439,13 +439,15 @@ private slots:
/**
* Opens the context menu on the current mouse position.
+ * @pos Position in screen coordinates.
* @item File item context. If item is null, the context menu
* should be applied to \a url.
* @url URL which contains \a item.
* @customActions Actions that should be added to the context menu,
* if the file item is null.
*/
- void openContextMenu(const KFileItem& item,
+ void openContextMenu(const QPoint& pos,
+ const KFileItem& item,
const KUrl& url,
const QList<QAction*>& customActions);