diff options
Diffstat (limited to 'include/sway/input/cursor.h')
-rw-r--r-- | include/sway/input/cursor.h | 17 |
1 files changed, 13 insertions, 4 deletions
diff --git a/include/sway/input/cursor.h b/include/sway/input/cursor.h index 7d66e699..527d0350 100644 --- a/include/sway/input/cursor.h +++ b/include/sway/input/cursor.h | |||
@@ -4,7 +4,7 @@ | |||
4 | #include <stdint.h> | 4 | #include <stdint.h> |
5 | #include <wlr/types/wlr_pointer_constraints_v1.h> | 5 | #include <wlr/types/wlr_pointer_constraints_v1.h> |
6 | #include <wlr/types/wlr_pointer_gestures_v1.h> | 6 | #include <wlr/types/wlr_pointer_gestures_v1.h> |
7 | #include <wlr/types/wlr_surface.h> | 7 | #include <wlr/types/wlr_compositor.h> |
8 | #include "sway/input/seat.h" | 8 | #include "sway/input/seat.h" |
9 | #include "config.h" | 9 | #include "config.h" |
10 | 10 | ||
@@ -35,7 +35,8 @@ struct sway_cursor { | |||
35 | pixman_region32_t confine; // invalid if active_constraint == NULL | 35 | pixman_region32_t confine; // invalid if active_constraint == NULL |
36 | bool active_confine_requires_warp; | 36 | bool active_confine_requires_warp; |
37 | 37 | ||
38 | struct wlr_pointer_gestures_v1 *pointer_gestures; | 38 | struct wl_listener hold_begin; |
39 | struct wl_listener hold_end; | ||
39 | struct wl_listener pinch_begin; | 40 | struct wl_listener pinch_begin; |
40 | struct wl_listener pinch_update; | 41 | struct wl_listener pinch_update; |
41 | struct wl_listener pinch_end; | 42 | struct wl_listener pinch_end; |
@@ -51,6 +52,7 @@ struct sway_cursor { | |||
51 | 52 | ||
52 | struct wl_listener touch_down; | 53 | struct wl_listener touch_down; |
53 | struct wl_listener touch_up; | 54 | struct wl_listener touch_up; |
55 | struct wl_listener touch_cancel; | ||
54 | struct wl_listener touch_motion; | 56 | struct wl_listener touch_motion; |
55 | struct wl_listener touch_frame; | 57 | struct wl_listener touch_frame; |
56 | bool simulating_pointer_from_touch; | 58 | bool simulating_pointer_from_touch; |
@@ -62,6 +64,7 @@ struct sway_cursor { | |||
62 | struct wl_listener tool_proximity; | 64 | struct wl_listener tool_proximity; |
63 | struct wl_listener tool_button; | 65 | struct wl_listener tool_button; |
64 | bool simulating_pointer_from_tool_tip; | 66 | bool simulating_pointer_from_tool_tip; |
67 | bool simulating_pointer_from_tool_button; | ||
65 | uint32_t tool_buttons; | 68 | uint32_t tool_buttons; |
66 | 69 | ||
67 | struct wl_listener request_set_cursor; | 70 | struct wl_listener request_set_cursor; |
@@ -105,12 +108,16 @@ void cursor_unhide(struct sway_cursor *cursor); | |||
105 | int cursor_get_timeout(struct sway_cursor *cursor); | 108 | int cursor_get_timeout(struct sway_cursor *cursor); |
106 | void cursor_notify_key_press(struct sway_cursor *cursor); | 109 | void cursor_notify_key_press(struct sway_cursor *cursor); |
107 | 110 | ||
111 | void pointer_motion(struct sway_cursor *cursor, uint32_t time_msec, | ||
112 | struct wlr_input_device *device, double dx, double dy, | ||
113 | double dx_unaccel, double dy_unaccel); | ||
114 | |||
108 | void dispatch_cursor_button(struct sway_cursor *cursor, | 115 | void dispatch_cursor_button(struct sway_cursor *cursor, |
109 | struct wlr_input_device *device, uint32_t time_msec, uint32_t button, | 116 | struct wlr_input_device *device, uint32_t time_msec, uint32_t button, |
110 | enum wlr_button_state state); | 117 | enum wl_pointer_button_state state); |
111 | 118 | ||
112 | void dispatch_cursor_axis(struct sway_cursor *cursor, | 119 | void dispatch_cursor_axis(struct sway_cursor *cursor, |
113 | struct wlr_event_pointer_axis *event); | 120 | struct wlr_pointer_axis_event *event); |
114 | 121 | ||
115 | void cursor_set_image(struct sway_cursor *cursor, const char *image, | 122 | void cursor_set_image(struct sway_cursor *cursor, const char *image, |
116 | struct wl_client *client); | 123 | struct wl_client *client); |
@@ -138,4 +145,6 @@ uint32_t get_mouse_button(const char *name, char **error); | |||
138 | 145 | ||
139 | const char *get_mouse_button_name(uint32_t button); | 146 | const char *get_mouse_button_name(uint32_t button); |
140 | 147 | ||
148 | void handle_request_set_cursor_shape(struct wl_listener *listener, void *data); | ||
149 | |||
141 | #endif | 150 | #endif |