diff options
author | Ken Moore <moorekou@gmail.com> | 2015-12-02 09:36:04 -0500 |
---|---|---|
committer | Ken Moore <moorekou@gmail.com> | 2015-12-02 09:36:04 -0500 |
commit | f5788dbc57dc21dd63c6beb7c8642115a4d7cb67 (patch) | |
tree | 7e84e0bbf71154ae5d6bff639a512046f4cdb95a /lumina-desktop/LDesktop.h | |
parent | Fix up the loading of locales through the StartMenu/Session. Now it will prop... (diff) | |
download | lumina-f5788dbc57dc21dd63c6beb7c8642115a4d7cb67.tar.gz lumina-f5788dbc57dc21dd63c6beb7c8642115a4d7cb67.tar.bz2 lumina-f5788dbc57dc21dd63c6beb7c8642115a4d7cb67.zip |
Fix up the context menu actions for the desktop a bit.
1) Now the desktop canvas itself will catch/maintain keyboard focus when clicked. This prevents issues with using a keyboard shortcut to simulate a right-click event causing strange behavior (what item (if any) has focus?).
2) Make sure that when the context menu is opened, it is always at the mouse cursor position (even if a key press opened the menu).
Diffstat (limited to 'lumina-desktop/LDesktop.h')
-rw-r--r-- | lumina-desktop/LDesktop.h | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/lumina-desktop/LDesktop.h b/lumina-desktop/LDesktop.h index 55f31cd7..14b6efc3 100644 --- a/lumina-desktop/LDesktop.h +++ b/lumina-desktop/LDesktop.h @@ -83,11 +83,9 @@ private slots: //Menu functions void UpdateMenu(bool fast = false); - void ShowMenu(const QPoint &pt = QPoint()){ + void ShowMenu(){ UpdateMenu(true); //run the fast version - //qDebug() << "Show Context Menu:" << QCursor::pos() << pt; - if(pt.isNull()){ deskMenu->popup(QCursor::pos()); } - else{ deskMenu->popup( bgWindow->mapToGlobal(pt)); } + deskMenu->popup(QCursor::pos()); //} } void UpdateWinMenu(); void winClicked(QAction*); |