diff options
| author | Marco Trevisan (Treviño) <mail@3v1n0.net> | 2016-08-24 17:01:57 +0200 |
|---|---|---|
| committer | Marco Trevisan (Treviño) <mail@3v1n0.net> | 2016-08-24 17:01:57 +0200 |
| commit | ffbe8909f66822865d0106de3f28c9325b0bfe63 (patch) | |
| tree | 449f2974a5d4afcb50ca89d706dd1a2d3dda7a34 /lockscreen | |
| parent | 54481061016bf4be7613730fb4cc98fbe7caa290 (diff) | |
PanelIndicatorEntryView: be the one who ungrabs the mouse pointer
Since it's the owner of the mouse, it's also the element that has to force-ungrab it. This allows to remove workarounds from PanelView, PanelMenuView, and LockScreenPanel (bzr r3788.9.7)
Diffstat (limited to 'lockscreen')
| -rw-r--r-- | lockscreen/LockScreenPanel.cpp | 7 | ||||
| -rw-r--r-- | lockscreen/LockScreenPanel.h | 2 |
2 files changed, 2 insertions, 7 deletions
diff --git a/lockscreen/LockScreenPanel.cpp b/lockscreen/LockScreenPanel.cpp index 19185b8be..ada4c3139 100644 --- a/lockscreen/LockScreenPanel.cpp +++ b/lockscreen/LockScreenPanel.cpp @@ -159,12 +159,7 @@ void Panel::OnEntryShowMenu(std::string const& entry_id, unsigned xid, int x, in if (!GetInputEventSensitivity()) return; - if (!active) - { - // This is ugly... But Nux fault! - WindowManager::Default().UnGrabMousePointer(CurrentTime, button, x, y); - active = true; - } + active = true; } void Panel::OnEntryActivateRequest(std::string const& entry_id) diff --git a/lockscreen/LockScreenPanel.h b/lockscreen/LockScreenPanel.h index 3d1b0edc7..2ed4c4c49 100644 --- a/lockscreen/LockScreenPanel.h +++ b/lockscreen/LockScreenPanel.h @@ -55,7 +55,7 @@ private: void AddIndicator(indicator::Indicator::Ptr const&); void RemoveIndicator(indicator::Indicator::Ptr const&); void OnIndicatorViewUpdated(); - void OnEntryActivated(std::string const& panel, std::string const& entry_id, nux::Rect const& geo); + void OnEntryActivated(std::string const& panel, std::string const& entry_id, nux::Rect const&); void OnEntryShowMenu(std::string const& entry_id, unsigned xid, int x, int y, unsigned button); void OnEntryActivateRequest(std::string const& entry_id); void OnEntryEvent(XEvent const&); |
