mirror of
https://github.com/gwenhael-le-moine/sway-patched-tray-menu.git
synced 2024-12-28 22:23:42 +01:00
Minor fixes to keyboard handling
This commit is contained in:
parent
9a7f48f872
commit
f30fb2452c
1 changed files with 3 additions and 1 deletions
|
@ -298,6 +298,8 @@ static bool handle_key(wlc_handle view, uint32_t time, const struct wlc_modifier
|
||||||
|
|
||||||
struct sway_mode *mode = config->current_mode;
|
struct sway_mode *mode = config->current_mode;
|
||||||
|
|
||||||
|
sym = tolower(sym);
|
||||||
|
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
if (state == WLC_KEY_STATE_PRESSED) {
|
if (state == WLC_KEY_STATE_PRESSED) {
|
||||||
|
@ -310,7 +312,7 @@ static bool handle_key(wlc_handle view, uint32_t time, const struct wlc_modifier
|
||||||
for (i = 0; i < mode->bindings->length; ++i) {
|
for (i = 0; i < mode->bindings->length; ++i) {
|
||||||
struct sway_binding *binding = mode->bindings->items[i];
|
struct sway_binding *binding = mode->bindings->items[i];
|
||||||
|
|
||||||
if ((modifiers->mods & binding->modifiers) == binding->modifiers) {
|
if ((modifiers->mods ^ binding->modifiers) == 0) {
|
||||||
bool match;
|
bool match;
|
||||||
int j;
|
int j;
|
||||||
for (j = 0; j < binding->keys->length; ++j) {
|
for (j = 0; j < binding->keys->length; ++j) {
|
||||||
|
|
Loading…
Reference in a new issue