From ab5f02771a7bd7161984765623f478a0a97a2b6d Mon Sep 17 00:00:00 2001 From: Carlos Garnacho Date: Tue, 19 Sep 2017 18:30:01 +0200 Subject: [PATCH] gdk/wayland: Don't make gtk_shell1 v2 mandatory It may result in a protocol error on older mutters, as GTK+ will invariably request a higher version than what's available. Make GTK+ also accept v1 if it's all the compositor has got. --- gdk/wayland/gdkdisplay-wayland.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gdk/wayland/gdkdisplay-wayland.c b/gdk/wayland/gdkdisplay-wayland.c index 30f4d4308a..31e19359c6 100644 --- a/gdk/wayland/gdkdisplay-wayland.c +++ b/gdk/wayland/gdkdisplay-wayland.c @@ -376,7 +376,7 @@ gdk_registry_handle_global (void *data, display_wayland->gtk_shell = wl_registry_bind(display_wayland->wl_registry, id, >k_shell1_interface, - GTK_SHELL1_VERSION); + MIN (version, GTK_SHELL1_VERSION)); _gdk_wayland_screen_set_has_gtk_shell (display_wayland->screen); display_wayland->gtk_shell_version = version; }