diff options
author | Daniel Kondor <kondor.dani@gmail.com> | 2020-10-20 10:08:24 +0800 |
---|---|---|
committer | Simon Ser <contact@emersion.fr> | 2020-10-20 09:12:07 +0200 |
commit | b4ed8b3d7414ff6280098da811f873e5c5146d27 (patch) | |
tree | efe2396c7cab3909781ea12c3f9113980cc4cdef | |
parent | 5217456b50f707780fce047b9d67b72f74475d3f (diff) |
foreign toplevel: send parent event only to clients that support it
-rw-r--r-- | types/wlr_foreign_toplevel_management_v1.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/types/wlr_foreign_toplevel_management_v1.c b/types/wlr_foreign_toplevel_management_v1.c index 5e7b731c..154f790c 100644 --- a/types/wlr_foreign_toplevel_management_v1.c +++ b/types/wlr_foreign_toplevel_management_v1.c @@ -408,6 +408,10 @@ void wlr_foreign_toplevel_handle_v1_set_fullscreen( static void toplevel_resource_send_parent( struct wl_resource *toplevel_resource, struct wlr_foreign_toplevel_handle_v1 *parent) { + if (wl_resource_get_version(toplevel_resource) < + ZWLR_FOREIGN_TOPLEVEL_HANDLE_V1_PARENT_SINCE_VERSION) { + return; + } struct wl_client *client = wl_resource_get_client(toplevel_resource); struct wl_resource *parent_resource = NULL; if (parent) { |