diff options
author | Damien <Dbroqua@users.noreply.github.com> | 2017-04-02 23:29:12 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-04-02 23:29:12 +0200 |
commit | 3e41cde9f99778ca30c03b97470c32780379db43 (patch) | |
tree | 18e2376acae06563166b5ea8b8cd6368cb9cddae /keyboards/clueboard/keymaps/unix_optimized/keymap.c | |
parent | e7347ff0de93ff823462b3ff2b4136b44dc576c0 (diff) | |
parent | 3448d5d4874a2775f85320a2be69edd241575d46 (diff) |
Merge pull request #19 from qmk/master
Merge from qmk
Diffstat (limited to 'keyboards/clueboard/keymaps/unix_optimized/keymap.c')
-rw-r--r-- | keyboards/clueboard/keymaps/unix_optimized/keymap.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/keyboards/clueboard/keymaps/unix_optimized/keymap.c b/keyboards/clueboard/keymaps/unix_optimized/keymap.c index 9fbd772405..7c1359954b 100644 --- a/keyboards/clueboard/keymaps/unix_optimized/keymap.c +++ b/keyboards/clueboard/keymaps/unix_optimized/keymap.c @@ -50,6 +50,7 @@ const uint16_t PROGMEM fn_actions[] = { void action_function(keyrecord_t *record, uint8_t id, uint8_t opt) { static uint8_t mods_pressed; + static bool mod_flag; switch (id) { case 0: @@ -61,6 +62,7 @@ void action_function(keyrecord_t *record, uint8_t id, uint8_t opt) { /* The key is being pressed. */ if (mods_pressed) { + mod_flag = true; add_key(KC_GRV); send_keyboard_report(); } else { @@ -70,7 +72,8 @@ void action_function(keyrecord_t *record, uint8_t id, uint8_t opt) { } else { /* The key is being released. */ - if (mods_pressed) { + if (mod_flag) { + mod_flag = false; del_key(KC_GRV); send_keyboard_report(); } else { |