[mutter] window: Cancel window grab ops on TOUCH_CANCEL events



commit 9889e6dadd0728c43762cf7c1497eb8017fa1310
Author: Jonas Dreßler <verdre v0yd nl>
Date:   Thu Mar 14 10:49:15 2019 +0100

    window: Cancel window grab ops on TOUCH_CANCEL events
    
    Window dragging should be cancelled when the touch sequences we're using
    are no longer available. Also listen to TOUCH_CANCEL events if the
    window is grabbed and cancel the grab op when a TOUCH_CANCEL event
    happens.
    
    Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/427>

 src/core/window.c | 4 ++++
 1 file changed, 4 insertions(+)
---
diff --git a/src/core/window.c b/src/core/window.c
index d99db949f8..b68dcb2b69 100644
--- a/src/core/window.c
+++ b/src/core/window.c
@@ -6565,6 +6565,10 @@ meta_window_handle_mouse_grab_op_event  (MetaWindow         *window,
         }
       return TRUE;
 
+    case CLUTTER_TOUCH_CANCEL:
+      end_grab_op (window, event);
+      return FALSE;
+
     default:
       return FALSE;
     }


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]