mirror of
https://github.com/swaywm/sway.git
synced 2025-11-02 09:01:40 -05:00
cmd_bind{sym,code}: Implement per-device bindings
bindsym --input-device=<identifier> ... bindcode --input-device=<identifier> ...
This commit is contained in:
parent
30dbb8eba0
commit
2e637b7368
9 changed files with 77 additions and 36 deletions
|
|
@ -43,6 +43,7 @@ enum binding_flags {
|
|||
struct sway_binding {
|
||||
enum binding_input_type type;
|
||||
int order;
|
||||
char *input;
|
||||
uint32_t flags;
|
||||
list_t *keys; // sorted in ascending order
|
||||
uint32_t modifiers;
|
||||
|
|
|
|||
|
|
@ -42,8 +42,9 @@ void sway_cursor_destroy(struct sway_cursor *cursor);
|
|||
struct sway_cursor *sway_cursor_create(struct sway_seat *seat);
|
||||
void cursor_send_pointer_motion(struct sway_cursor *cursor, uint32_t time_msec,
|
||||
bool allow_refocusing);
|
||||
void dispatch_cursor_button(struct sway_cursor *cursor, uint32_t time_msec,
|
||||
uint32_t button, enum wlr_button_state state);
|
||||
void dispatch_cursor_button(struct sway_cursor *cursor,
|
||||
struct wlr_input_device *device, uint32_t time_msec, uint32_t button,
|
||||
enum wlr_button_state state);
|
||||
|
||||
void cursor_set_image(struct sway_cursor *cursor, const char *image,
|
||||
struct wl_client *client);
|
||||
|
|
|
|||
|
|
@ -63,5 +63,6 @@ struct sway_seat *input_manager_current_seat(struct sway_input_manager *input);
|
|||
|
||||
struct input_config *input_device_get_config(struct sway_input_device *device);
|
||||
|
||||
char *input_device_get_identifier(struct wlr_input_device *device);
|
||||
|
||||
#endif
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue