[gtk/wip/matthiasc/popup5: 78/115] surface: Avoid autodismissal on button release
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk/wip/matthiasc/popup5: 78/115] surface: Avoid autodismissal on button release
- Date: Sun, 19 May 2019 04:50:57 +0000 (UTC)
commit 0d3c6684d911a268aad053029b87355e4b69deeb
Author: Matthias Clasen <mclasen redhat com>
Date: Tue Apr 30 01:45:37 2019 +0000
surface: Avoid autodismissal on button release
At least under X, implicit grabs guarantee
that the release goes to the same surface
as the press, which is bad news if we show
an autodismiss surface in response to it.
Until we have a proper solution, just
ignore button release events for autodismissal.
gdk/gdksurface.c | 6 ++++++
1 file changed, 6 insertions(+)
---
diff --git a/gdk/gdksurface.c b/gdk/gdksurface.c
index dab874d209..8da7924c0d 100644
--- a/gdk/gdksurface.c
+++ b/gdk/gdksurface.c
@@ -4023,7 +4023,13 @@ check_auto_dismissal (GdkEvent *event)
switch ((guint) gdk_event_get_event_type (event))
{
case GDK_BUTTON_PRESS:
+#if 0
+ // FIXME: we need to ignore the release that is paired
+ // with the press starting the grab - due to implicit
+ // grabs, it will be delivered to the same place as the
+ // press, and will cause the auto dismissal to be triggered.
case GDK_BUTTON_RELEASE:
+#endif
case GDK_TOUCH_BEGIN:
case GDK_TOUCH_END:
case GDK_TOUCH_CANCEL:
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]