mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2024-09-19 21:40:22 +00:00
wayland: Try harder to be compatible
We can keep the old unexport_handle api working in the case that there is only a single exported handle.
This commit is contained in:
parent
250a5c0dfd
commit
89d993b6ec
@ -2557,6 +2557,20 @@ gdk_wayland_toplevel_export_handle (GdkToplevel *toplevel,
|
||||
void
|
||||
gdk_wayland_toplevel_unexport_handle (GdkToplevel *toplevel)
|
||||
{
|
||||
GdkWaylandToplevel *wayland_toplevel = GDK_WAYLAND_TOPLEVEL (toplevel);
|
||||
|
||||
if (wayland_toplevel->exported != NULL &&
|
||||
wayland_toplevel->exported->next == NULL)
|
||||
{
|
||||
GdkWaylandExported *exported = wayland_toplevel->exported->data;
|
||||
|
||||
if (exported->handle)
|
||||
{
|
||||
gdk_toplevel_unexport_handle (toplevel, exported->handle);
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
g_warning ("Use gdk_wayland_toplevel_drop_exported_handle()");
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user