diff options
author | Drew DeVault <sir@cmpwn.com> | 2016-01-07 16:38:33 -0500 |
---|---|---|
committer | Drew DeVault <sir@cmpwn.com> | 2016-01-07 16:38:33 -0500 |
commit | 320c2915b0aeb4bbecb753bf00091e24905c5652 (patch) | |
tree | a854f1068b7360952835b38bc38a1138bf1de7f0 /include | |
parent | Merge pull request #434 from mikkeloscar/detect-modifier (diff) | |
parent | Implement bindsym --release (diff) | |
download | sway-320c2915b0aeb4bbecb753bf00091e24905c5652.tar.gz sway-320c2915b0aeb4bbecb753bf00091e24905c5652.tar.zst sway-320c2915b0aeb4bbecb753bf00091e24905c5652.zip |
Merge pull request #439 from mikkeloscar/bindsym-release
Implement bindsym --release
Diffstat (limited to 'include')
-rw-r--r-- | include/config.h | 1 | ||||
-rw-r--r-- | include/input_state.h | 3 |
2 files changed, 4 insertions, 0 deletions
diff --git a/include/config.h b/include/config.h index 5e1c39f3..8220f804 100644 --- a/include/config.h +++ b/include/config.h | |||
@@ -22,6 +22,7 @@ struct sway_variable { | |||
22 | */ | 22 | */ |
23 | struct sway_binding { | 23 | struct sway_binding { |
24 | int order; | 24 | int order; |
25 | bool release; | ||
25 | list_t *keys; | 26 | list_t *keys; |
26 | uint32_t modifiers; | 27 | uint32_t modifiers; |
27 | char *command; | 28 | char *command; |
diff --git a/include/input_state.h b/include/input_state.h index 79e27d91..903301fb 100644 --- a/include/input_state.h +++ b/include/input_state.h | |||
@@ -9,6 +9,9 @@ | |||
9 | // returns true if key has been pressed, otherwise false | 9 | // returns true if key has been pressed, otherwise false |
10 | bool check_key(uint32_t key_sym, uint32_t key_code); | 10 | bool check_key(uint32_t key_sym, uint32_t key_code); |
11 | 11 | ||
12 | // returns true if key_sym matches latest released key. | ||
13 | bool check_released_key(uint32_t key_sym); | ||
14 | |||
12 | // sets a key as pressed | 15 | // sets a key as pressed |
13 | void press_key(uint32_t key_sym, uint32_t key_code); | 16 | void press_key(uint32_t key_sym, uint32_t key_code); |
14 | 17 | ||