diff options
author | taiyu <taiyu.len@gmail.com> | 2015-08-23 19:11:06 -0700 |
---|---|---|
committer | taiyu <taiyu.len@gmail.com> | 2015-08-23 19:11:06 -0700 |
commit | b054ac9d4973c8803ff8981eb1f1a754434efe4d (patch) | |
tree | 4c4f5ca7868eae946f9e85bbe1b56a03fcbb522c | |
parent | split_string memory leaks cleanedup (diff) | |
parent | Minor fixes to keyboard handling (diff) | |
download | sway-b054ac9d4973c8803ff8981eb1f1a754434efe4d.tar.gz sway-b054ac9d4973c8803ff8981eb1f1a754434efe4d.tar.zst sway-b054ac9d4973c8803ff8981eb1f1a754434efe4d.zip |
Merge branch 'master' of https://github.com/SirCmpwn/sway
merge
-rw-r--r-- | sway/handlers.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/sway/handlers.c b/sway/handlers.c index 27f6d294..3a4e31ae 100644 --- a/sway/handlers.c +++ b/sway/handlers.c | |||
@@ -298,6 +298,8 @@ static bool handle_key(wlc_handle view, uint32_t time, const struct wlc_modifier | |||
298 | 298 | ||
299 | struct sway_mode *mode = config->current_mode; | 299 | struct sway_mode *mode = config->current_mode; |
300 | 300 | ||
301 | sym = tolower(sym); | ||
302 | |||
301 | int i; | 303 | int i; |
302 | 304 | ||
303 | if (state == WLC_KEY_STATE_PRESSED) { | 305 | if (state == WLC_KEY_STATE_PRESSED) { |
@@ -310,7 +312,7 @@ static bool handle_key(wlc_handle view, uint32_t time, const struct wlc_modifier | |||
310 | for (i = 0; i < mode->bindings->length; ++i) { | 312 | for (i = 0; i < mode->bindings->length; ++i) { |
311 | struct sway_binding *binding = mode->bindings->items[i]; | 313 | struct sway_binding *binding = mode->bindings->items[i]; |
312 | 314 | ||
313 | if ((modifiers->mods & binding->modifiers) == binding->modifiers) { | 315 | if ((modifiers->mods ^ binding->modifiers) == 0) { |
314 | bool match; | 316 | bool match; |
315 | int j; | 317 | int j; |
316 | for (j = 0; j < binding->keys->length; ++j) { | 318 | for (j = 0; j < binding->keys->length; ++j) { |