From c545ffac43231893d51a5976644dba447e75bb3a Mon Sep 17 00:00:00 2001 From: JoseExposito Date: Sun, 18 Apr 2021 20:10:23 +0200 Subject: [PATCH] wayland/pointer-gestures: Update protocol to v2 Update the pointer gestures protocol to version 2 and implement the new release method. Part-of: --- src/wayland/meta-wayland-pointer-gestures.c | 10 +++++++++- src/wayland/meta-wayland-versions.h | 2 +- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/src/wayland/meta-wayland-pointer-gestures.c b/src/wayland/meta-wayland-pointer-gestures.c index 7222a8a8c..a83d86004 100644 --- a/src/wayland/meta-wayland-pointer-gestures.c +++ b/src/wayland/meta-wayland-pointer-gestures.c @@ -54,9 +54,17 @@ gestures_get_pinch (struct wl_client *client, meta_wayland_pointer_gesture_pinch_create_new_resource (pointer, client, resource, id); } +static void +gestures_release (struct wl_client *client, + struct wl_resource *resource) +{ + wl_resource_destroy (resource); +} + static const struct zwp_pointer_gestures_v1_interface pointer_gestures_interface = { gestures_get_swipe, - gestures_get_pinch + gestures_get_pinch, + gestures_release }; static void diff --git a/src/wayland/meta-wayland-versions.h b/src/wayland/meta-wayland-versions.h index 0e859b900..6f26aa6be 100644 --- a/src/wayland/meta-wayland-versions.h +++ b/src/wayland/meta-wayland-versions.h @@ -45,7 +45,7 @@ #define META_XSERVER_VERSION 1 #define META_GTK_SHELL1_VERSION 5 #define META_WL_SUBCOMPOSITOR_VERSION 1 -#define META_ZWP_POINTER_GESTURES_V1_VERSION 1 +#define META_ZWP_POINTER_GESTURES_V1_VERSION 2 #define META_ZXDG_EXPORTER_V1_VERSION 1 #define META_ZXDG_IMPORTER_V1_VERSION 1 #define META_ZWP_LINUX_DMABUF_V1_VERSION 3