diff options
author | vil <vil@vil.lv> | 2018-06-17 17:37:58 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-06-17 17:37:58 -0400 |
commit | 8884a063c1c11cb1e2370c3f172fcb9ebd59c991 (patch) | |
tree | 7f2fc2f6cd4ba948df2e9e119e2e109973f638db /include | |
parent | Set pool_buffers busy when handing them out (diff) | |
parent | Merge pull request #2140 from Hello71/patch-2 (diff) | |
download | sway-8884a063c1c11cb1e2370c3f172fcb9ebd59c991.tar.gz sway-8884a063c1c11cb1e2370c3f172fcb9ebd59c991.tar.zst sway-8884a063c1c11cb1e2370c3f172fcb9ebd59c991.zip |
Merge branch 'master' into mark-pool-buffers-busy
Diffstat (limited to 'include')
-rw-r--r-- | include/sway/config.h | 2 | ||||
-rw-r--r-- | include/sway/input/keyboard.h | 5 | ||||
-rw-r--r-- | include/sway/input/seat.h | 20 | ||||
-rw-r--r-- | include/sway/tree/layout.h | 1 |
4 files changed, 25 insertions, 3 deletions
diff --git a/include/sway/config.h b/include/sway/config.h index 81e9c382..e75b0664 100644 --- a/include/sway/config.h +++ b/include/sway/config.h | |||
@@ -30,7 +30,7 @@ struct sway_binding { | |||
30 | bool release; | 30 | bool release; |
31 | bool locked; | 31 | bool locked; |
32 | bool bindcode; | 32 | bool bindcode; |
33 | list_t *keys; | 33 | list_t *keys; // sorted in ascending order |
34 | uint32_t modifiers; | 34 | uint32_t modifiers; |
35 | char *command; | 35 | char *command; |
36 | }; | 36 | }; |
diff --git a/include/sway/input/keyboard.h b/include/sway/input/keyboard.h index e99a54b1..6713398e 100644 --- a/include/sway/input/keyboard.h +++ b/include/sway/input/keyboard.h | |||
@@ -21,7 +21,9 @@ struct sway_shortcut_state { | |||
21 | * including duplicates when a keycode generates multiple key ids. | 21 | * including duplicates when a keycode generates multiple key ids. |
22 | */ | 22 | */ |
23 | uint32_t pressed_keycodes[SWAY_KEYBOARD_PRESSED_KEYS_CAP]; | 23 | uint32_t pressed_keycodes[SWAY_KEYBOARD_PRESSED_KEYS_CAP]; |
24 | int last_key_index; | 24 | uint32_t last_keycode; |
25 | uint32_t last_raw_modifiers; | ||
26 | size_t npressed; | ||
25 | }; | 27 | }; |
26 | 28 | ||
27 | struct sway_keyboard { | 29 | struct sway_keyboard { |
@@ -36,7 +38,6 @@ struct sway_keyboard { | |||
36 | struct sway_shortcut_state state_keysyms_raw; | 38 | struct sway_shortcut_state state_keysyms_raw; |
37 | struct sway_shortcut_state state_keycodes; | 39 | struct sway_shortcut_state state_keycodes; |
38 | struct sway_binding *held_binding; | 40 | struct sway_binding *held_binding; |
39 | uint32_t last_modifiers; | ||
40 | }; | 41 | }; |
41 | 42 | ||
42 | struct sway_keyboard *sway_keyboard_create(struct sway_seat *seat, | 43 | struct sway_keyboard *sway_keyboard_create(struct sway_seat *seat, |
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 | ||