diff options
author | tmk <nobody@nowhere> | 2013-02-13 11:22:33 +0900 |
---|---|---|
committer | tmk <nobody@nowhere> | 2013-02-13 11:22:33 +0900 |
commit | 7054203e16af627a921b503a9508ce789913471d (patch) | |
tree | 9e5d1fd4aed7682e0e45579e6d6c311773fd50df /common/command.c | |
parent | 821563417565776d2dc3a02b0265e6fcd5218739 (diff) | |
parent | 2fe406de3ae4210e90acbf65ae926fcf382938e6 (diff) |
Merge branch 'transparent'
Diffstat (limited to 'common/command.c')
-rw-r--r-- | common/command.c | 21 |
1 files changed, 7 insertions, 14 deletions
diff --git a/common/command.c b/common/command.c index 6d4e4c642d..7bb2a23f19 100644 --- a/common/command.c +++ b/common/command.c @@ -263,23 +263,16 @@ static bool command_common(uint8_t code) #endif case KC_0: case KC_F10: + clear_keyboard(); switch_layer(0); break; - case KC_1: - case KC_F1: - switch_layer(1); - break; - case KC_2: - case KC_F2: - switch_layer(2); - break; - case KC_3: - case KC_F3: - switch_layer(3); + case KC_1 ... KC_9: + clear_keyboard(); + switch_layer((code - KC_1) + 1); break; - case KC_4: - case KC_F4: - switch_layer(4); + case KC_F1 ... KC_F9: + clear_keyboard(); + switch_layer((code - KC_F1) + 1); break; default: print("?"); |