forked from AuroraMiddleware/gtk
Merge branch 'fix-xdg-activation-set-surface-gtk-3-24' into 'gtk-3-24'
Backport "gdk/wayland: set requesting surface to xdg-activation" to gtk-3-24 See merge request GNOME/gtk!5398
This commit is contained in:
commit
13647e0144
@ -3850,6 +3850,8 @@ gdk_wayland_window_focus (GdkWindow *window,
|
||||
{
|
||||
struct xdg_activation_token_v1 *token;
|
||||
struct wl_event_queue *event_queue;
|
||||
struct wl_surface *wl_surface = NULL;
|
||||
GdkWindow *focus_window;
|
||||
|
||||
event_queue = wl_display_create_queue (display_wayland->wl_display);
|
||||
|
||||
@ -3862,8 +3864,13 @@ gdk_wayland_window_focus (GdkWindow *window,
|
||||
xdg_activation_token_v1_set_serial (token,
|
||||
_gdk_wayland_seat_get_last_implicit_grab_serial (seat, NULL),
|
||||
gdk_wayland_seat_get_wl_seat (seat));
|
||||
xdg_activation_token_v1_set_surface (token,
|
||||
gdk_wayland_window_get_wl_surface (window));
|
||||
|
||||
focus_window = gdk_wayland_device_get_focus (gdk_seat_get_keyboard (seat));
|
||||
if (focus_window)
|
||||
wl_surface = gdk_wayland_window_get_wl_surface (focus_window);
|
||||
if (wl_surface)
|
||||
xdg_activation_token_v1_set_surface (token, wl_surface);
|
||||
|
||||
xdg_activation_token_v1_commit (token);
|
||||
|
||||
while (startup_id == NULL)
|
||||
|
Loading…
Reference in New Issue
Block a user