diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/sway/input/seat.h | 20 | ||||
-rw-r--r-- | include/sway/tree/layout.h | 1 |
2 files changed, 21 insertions, 0 deletions
diff --git a/include/sway/input/seat.h b/include/sway/input/seat.h index 2e4da438..1f7792ba 100644 --- a/include/sway/input/seat.h +++ b/include/sway/input/seat.h | |||
@@ -21,6 +21,19 @@ struct sway_seat_container { | |||
21 | struct wl_listener destroy; | 21 | struct wl_listener destroy; |
22 | }; | 22 | }; |
23 | 23 | ||
24 | struct sway_drag_icon { | ||
25 | struct sway_seat *seat; | ||
26 | struct wlr_drag_icon *wlr_drag_icon; | ||
27 | struct wl_list link; // sway_root::drag_icons | ||
28 | |||
29 | double x, y; // in layout-local coordinates | ||
30 | |||
31 | struct wl_listener surface_commit; | ||
32 | struct wl_listener map; | ||
33 | struct wl_listener unmap; | ||
34 | struct wl_listener destroy; | ||
35 | }; | ||
36 | |||
24 | struct sway_seat { | 37 | struct sway_seat { |
25 | struct wlr_seat *wlr_seat; | 38 | struct wlr_seat *wlr_seat; |
26 | struct sway_cursor *cursor; | 39 | struct sway_cursor *cursor; |
@@ -35,8 +48,13 @@ struct sway_seat { | |||
35 | // If exclusive_client is set, no other clients will receive input events | 48 | // If exclusive_client is set, no other clients will receive input events |
36 | struct wl_client *exclusive_client; | 49 | struct wl_client *exclusive_client; |
37 | 50 | ||
51 | // Last touch point | ||
52 | int32_t touch_id; | ||
53 | double touch_x, touch_y; | ||
54 | |||
38 | struct wl_listener focus_destroy; | 55 | struct wl_listener focus_destroy; |
39 | struct wl_listener new_container; | 56 | struct wl_listener new_container; |
57 | struct wl_listener new_drag_icon; | ||
40 | 58 | ||
41 | struct wl_list devices; // sway_seat_device::link | 59 | struct wl_list devices; // sway_seat_device::link |
42 | 60 | ||
@@ -114,4 +132,6 @@ struct seat_config *seat_get_config(struct sway_seat *seat); | |||
114 | 132 | ||
115 | bool seat_is_input_allowed(struct sway_seat *seat, struct wlr_surface *surface); | 133 | bool seat_is_input_allowed(struct sway_seat *seat, struct wlr_surface *surface); |
116 | 134 | ||
135 | void drag_icon_update_position(struct sway_drag_icon *icon); | ||
136 | |||
117 | #endif | 137 | #endif |
diff --git a/include/sway/tree/layout.h b/include/sway/tree/layout.h index cd131056..ba265623 100644 --- a/include/sway/tree/layout.h +++ b/include/sway/tree/layout.h | |||
@@ -28,6 +28,7 @@ struct sway_root { | |||
28 | struct wl_listener output_layout_change; | 28 | struct wl_listener output_layout_change; |
29 | 29 | ||
30 | struct wl_list xwayland_unmanaged; // sway_xwayland_unmanaged::link | 30 | struct wl_list xwayland_unmanaged; // sway_xwayland_unmanaged::link |
31 | struct wl_list drag_icons; // sway_drag_icon::link | ||
31 | 32 | ||
32 | struct wlr_texture *debug_tree; | 33 | struct wlr_texture *debug_tree; |
33 | 34 | ||