gdk/wayland: Use serial of the latest implicit grab available
authorCarlos Garnacho <carlosg@gnome.org>
Wed, 19 Oct 2022 10:46:09 +0000 (12:46 +0200)
committerSimon McVittie <smcv@debian.org>
Tue, 6 Dec 2022 11:52:29 +0000 (11:52 +0000)
commit015c78cc9a2fd863ea642e602743fa2e484d5a14
tree84ddb219cfbff0df3115aff017099cc04ba8c489
parent81e72c94b570fcdb5a1c38bc0c1669bdd07f4e70
gdk/wayland: Use serial of the latest implicit grab available

When getting the serial for primary/clipboard selections we used a
function that largely relied on a GdkEvent being passed. We have
another available function that looks up the most recent serial
given the ongoing touch/tablet input as well.

This is the second best, compared to actually knowing the
input/device from the event that was received by the UI an triggered
the clipboard operation, and is already in use in other places
(e.g. window dragging). It is valid for these situations too.

Bug: https://gitlab.gnome.org/GNOME/gtk/-/issues/5250
Origin: upstream, 4.8.3, commit:873c304a9460ab30c4acf8e922605412cbededf8

Gbp-Pq: Name gdk-wayland-Use-serial-of-the-latest-implicit-grab-availa.patch
gdk/wayland/gdkdevice-wayland.c
gdk/wayland/gdkprimary-wayland.c