[gnome-shell/gnome-3-8] backgroundMenu: Ignore releases when using long-press
- From: Jasper St. Pierre <jstpierre src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-shell/gnome-3-8] backgroundMenu: Ignore releases when using long-press
- Date: Fri, 26 Apr 2013 15:24:44 +0000 (UTC)
commit 77d21e53d089d54874d75fe74fe811fca922870e
Author: Jasper St. Pierre <jstpierre mecheye net>
Date: Tue Apr 23 16:39:29 2013 -0400
backgroundMenu: Ignore releases when using long-press
Otherwise, a release from the long-press will be seen as a
button event that should close the menu.
https://bugzilla.gnome.org/show_bug.cgi?id=697203
js/ui/backgroundMenu.js | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
---
diff --git a/js/ui/backgroundMenu.js b/js/ui/backgroundMenu.js
index 1328b3f..06e698c 100644
--- a/js/ui/backgroundMenu.js
+++ b/js/ui/backgroundMenu.js
@@ -46,8 +46,10 @@ function addBackgroundMenu(actor) {
clickAction.connect('long-press', function(action, actor, state) {
if (state == Clutter.LongPressState.QUERY)
return action.get_button() == 1 && !actor._backgroundMenu.isOpen;
- if (state == Clutter.LongPressState.ACTIVATE)
+ if (state == Clutter.LongPressState.ACTIVATE) {
openMenu();
+ actor._backgroundManager.ignoreRelease();
+ }
return true;
});
clickAction.connect('clicked', function(action) {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]