From 6ae521bb325493d32fa2e3be341886163b0d7df9 Mon Sep 17 00:00:00 2001 From: Pier Luigi Fiorini Date: Wed, 11 Feb 2015 06:46:00 +0000 Subject: [PATCH] wayland: Do not require latest wl_seat Some compositors might not offer wl_seat 4 resulting in GTK+ clients not working on that compositor. wl_seat 4 introduces keyboard repeat information, but when that information is missing it is retrieved from settings, hence there's no reason to require wl_seat 4. This patch was tested against QtCompositor (5.5, dev branch) and Weston 1.6.1. Reviewed-by: Daniel Stone https://bugzilla.gnome.org/show_bug.cgi?id=744172 --- 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 007d37a8f8..0be9ab6965 100644 --- a/gdk/wayland/gdkdisplay-wayland.c +++ b/gdk/wayland/gdkdisplay-wayland.c @@ -172,7 +172,7 @@ gdk_registry_handle_global(void *data, struct wl_registry *registry, uint32_t id wl_registry_bind(display_wayland->wl_registry, id, &wl_output_interface, MIN (version, 2)); _gdk_wayland_screen_add_output(display_wayland->screen, id, output, MIN (version, 2)); } else if (strcmp(interface, "wl_seat") == 0) { - seat = wl_registry_bind(display_wayland->wl_registry, id, &wl_seat_interface, 4); + seat = wl_registry_bind(display_wayland->wl_registry, id, &wl_seat_interface, MIN (version, 4)); _gdk_wayland_device_manager_add_seat (gdk_display->device_manager, id, seat); } else if (strcmp(interface, "wl_data_device_manager") == 0) { display_wayland->data_device_manager =