Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(207)

Unified Diff: third_party/wayland-protocols/protocol/stylus-protocol.c

Issue 2144283003: wayland-protocols: Add protocol for stylus support (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: git checkout stylus Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/wayland-protocols/protocol/stylus-protocol.c
diff --git a/third_party/wayland-protocols/protocol/gaming-input-protocol.c b/third_party/wayland-protocols/protocol/stylus-protocol.c
similarity index 63%
copy from third_party/wayland-protocols/protocol/gaming-input-protocol.c
copy to third_party/wayland-protocols/protocol/stylus-protocol.c
index beaddbda9840506d97e1a8088c19de8aafe91be0..5cc1ea17acbd270b57322d521378936f2df324db 100644
--- a/third_party/wayland-protocols/protocol/gaming-input-protocol.c
+++ b/third_party/wayland-protocols/protocol/stylus-protocol.c
@@ -25,42 +25,40 @@
#include <stdint.h>
#include "wayland-util.h"
-extern const struct wl_interface zwp_gamepad_v1_interface;
-extern const struct wl_interface wl_seat_interface;
+extern const struct wl_interface zwp_pointer_stylus_v1_interface;
+extern const struct wl_interface wl_pointer_interface;
static const struct wl_interface *types[] = {
NULL,
NULL,
NULL,
- NULL,
- &zwp_gamepad_v1_interface,
- &wl_seat_interface,
+ &zwp_pointer_stylus_v1_interface,
+ &wl_pointer_interface,
};
-static const struct wl_message zwp_gaming_input_v1_requests[] = {
- { "get_gamepad", "no", types + 4 },
+static const struct wl_message zwp_stylus_v1_requests[] = {
+ { "get_pointer_stylus", "no", types + 3 },
};
-WL_EXPORT const struct wl_interface zwp_gaming_input_v1_interface = {
- "zwp_gaming_input_v1", 1,
- 1, zwp_gaming_input_v1_requests,
+WL_EXPORT const struct wl_interface zwp_stylus_v1_interface = {
+ "zwp_stylus_v1", 1,
+ 1, zwp_stylus_v1_requests,
0, NULL,
};
-static const struct wl_message zwp_gamepad_v1_requests[] = {
+static const struct wl_message zwp_pointer_stylus_v1_requests[] = {
{ "destroy", "", types + 0 },
};
-static const struct wl_message zwp_gamepad_v1_events[] = {
- { "state_change", "u", types + 0 },
- { "axis", "uuf", types + 0 },
- { "button", "uuuf", types + 0 },
- { "frame", "u", types + 0 },
+static const struct wl_message zwp_pointer_stylus_v1_events[] = {
+ { "tool_change", "u", types + 0 },
+ { "force", "uf", types + 0 },
+ { "tilt", "uff", types + 0 },
};
-WL_EXPORT const struct wl_interface zwp_gamepad_v1_interface = {
- "zwp_gamepad_v1", 1,
- 1, zwp_gamepad_v1_requests,
- 4, zwp_gamepad_v1_events,
+WL_EXPORT const struct wl_interface zwp_pointer_stylus_v1_interface = {
+ "zwp_pointer_stylus_v1", 1,
+ 1, zwp_pointer_stylus_v1_requests,
+ 3, zwp_pointer_stylus_v1_events,
};

Powered by Google App Engine
This is Rietveld 408576698