mirror of
https://github.com/brl/mutter.git
synced 2024-12-23 11:32:04 +00:00
display: cancel wayland client touches when the compositor is grabbed
When a compositor grab begins, clients will stop receiving events, so any ongoing sequence at that time must be cancelled. https://bugzilla.gnome.org/show_bug.cgi?id=733631
This commit is contained in:
parent
63c7591698
commit
70aee2d95e
@ -74,7 +74,7 @@
|
||||
#include "meta-window-group.h"
|
||||
#include "meta-stage.h"
|
||||
#include "window-private.h" /* to check window->hidden */
|
||||
#include "display-private.h" /* for meta_display_lookup_x_window() */
|
||||
#include "display-private.h" /* for meta_display_lookup_x_window() and meta_display_cancel_touch() */
|
||||
#include "util-private.h"
|
||||
#include "frame.h"
|
||||
#include <X11/extensions/shape.h>
|
||||
@ -365,7 +365,10 @@ meta_begin_modal_for_plugin (MetaCompositor *compositor,
|
||||
display->grab_window, display->grab_op);
|
||||
|
||||
if (meta_is_wayland_compositor ())
|
||||
meta_display_sync_wayland_input_focus (display);
|
||||
{
|
||||
meta_display_sync_wayland_input_focus (display);
|
||||
meta_display_cancel_touch (display);
|
||||
}
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
@ -454,4 +454,6 @@ gboolean meta_display_request_restart (MetaDisplay *display);
|
||||
void meta_restart_init (void);
|
||||
void meta_restart_finish (void);
|
||||
|
||||
void meta_display_cancel_touch (MetaDisplay *display);
|
||||
|
||||
#endif
|
||||
|
@ -461,7 +461,7 @@ meta_set_gnome_wm_keybindings (const char *wm_keybindings)
|
||||
gnome_wm_keybindings = wm_keybindings;
|
||||
}
|
||||
|
||||
static void
|
||||
void
|
||||
meta_display_cancel_touch (MetaDisplay *display)
|
||||
{
|
||||
MetaWaylandCompositor *compositor;
|
||||
@ -1869,7 +1869,10 @@ meta_display_begin_grab_op (MetaDisplay *display,
|
||||
display->grab_anchor_window_pos = display->grab_initial_window_pos;
|
||||
|
||||
if (meta_is_wayland_compositor ())
|
||||
meta_display_sync_wayland_input_focus (display);
|
||||
{
|
||||
meta_display_sync_wayland_input_focus (display);
|
||||
meta_display_cancel_touch (display);
|
||||
}
|
||||
|
||||
g_signal_emit (display, display_signals[GRAB_OP_BEGIN], 0,
|
||||
screen, display->grab_window, display->grab_op);
|
||||
|
Loading…
Reference in New Issue
Block a user