mirror of
https://github.com/brl/mutter.git
synced 2024-12-24 12:02:04 +00:00
display: Emit 'grab-op-end' signal after ungrab happened
We're currently emitting the 'grab-op-end' signal when the grab prerequisites are met, but when display->grab_op is still set to a not-NONE value and thus meta_display_get_grab_op() would return that in the signal callback. And more importantly when this is emitted, devices are still grabbed. Instead, emit this signal as soon as we've unset all the grab properties and released the devices. Helps with https://gitlab.gnome.org/GNOME/gnome-shell/issues/1326 https://gitlab.gnome.org/GNOME/mutter/merge_requests/596
This commit is contained in:
parent
bbfaf8204b
commit
e2bea48073
@ -1837,9 +1837,6 @@ meta_display_end_grab_op (MetaDisplay *display,
|
|||||||
|
|
||||||
g_assert (grab_window != NULL);
|
g_assert (grab_window != NULL);
|
||||||
|
|
||||||
g_signal_emit (display, display_signals[GRAB_OP_END], 0,
|
|
||||||
display, grab_window, grab_op);
|
|
||||||
|
|
||||||
/* We need to reset this early, since the
|
/* We need to reset this early, since the
|
||||||
* meta_window_grab_op_ended callback relies on this being
|
* meta_window_grab_op_ended callback relies on this being
|
||||||
* up to date. */
|
* up to date. */
|
||||||
@ -1891,6 +1888,9 @@ meta_display_end_grab_op (MetaDisplay *display,
|
|||||||
|
|
||||||
if (meta_is_wayland_compositor ())
|
if (meta_is_wayland_compositor ())
|
||||||
meta_display_sync_wayland_input_focus (display);
|
meta_display_sync_wayland_input_focus (display);
|
||||||
|
|
||||||
|
g_signal_emit (display, display_signals[GRAB_OP_END], 0,
|
||||||
|
display, grab_window, grab_op);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Loading…
Reference in New Issue
Block a user