[mutter] MetaWaylandPopup: Dismiss popup when grab is cancelled
- From: Jonas Ådahl <jadahl src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [mutter] MetaWaylandPopup: Dismiss popup when grab is cancelled
- Date: Wed, 12 Oct 2016 02:50:51 +0000 (UTC)
commit 9de6de5802fb7559c71617bf2944100703cbdbff
Author: Jonas Ådahl <jadahl gmail com>
Date: Wed Sep 21 14:45:51 2016 +0800
MetaWaylandPopup: Dismiss popup when grab is cancelled
Dismiss the popup when the grab is cancelled, so that if the grab is
ended for whatever reason (such as VT switching or the last pointer
being disconnected), it doesn't try to end the grab when it isn't
active.
This fixes a crash when VT switching back and forth while a popup grab
is active.
https://bugzilla.gnome.org/show_bug.cgi?id=771858
src/wayland/meta-wayland-popup.c | 9 ++++++++-
1 files changed, 8 insertions(+), 1 deletions(-)
---
diff --git a/src/wayland/meta-wayland-popup.c b/src/wayland/meta-wayland-popup.c
index f9141dd..1b36d00 100644
--- a/src/wayland/meta-wayland-popup.c
+++ b/src/wayland/meta-wayland-popup.c
@@ -141,10 +141,17 @@ popup_grab_button (MetaWaylandPointerGrab *grab,
meta_wayland_pointer_end_popup_grab (grab->pointer);
}
+static void
+popup_grab_cancel (MetaWaylandPointerGrab *grab)
+{
+ meta_wayland_pointer_end_popup_grab (grab->pointer);
+}
+
static MetaWaylandPointerGrabInterface popup_grab_interface = {
popup_grab_focus,
popup_grab_motion,
- popup_grab_button
+ popup_grab_button,
+ popup_grab_cancel
};
MetaWaylandPopupGrab *
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]