diff options
Diffstat (limited to 'apps/keymaps/keymap-hdd1630.c')
-rw-r--r-- | apps/keymaps/keymap-hdd1630.c | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/apps/keymaps/keymap-hdd1630.c b/apps/keymaps/keymap-hdd1630.c index 6b38983d08..deb77307b8 100644 --- a/apps/keymaps/keymap-hdd1630.c +++ b/apps/keymaps/keymap-hdd1630.c | |||
@@ -282,6 +282,27 @@ static const struct button_mapping button_context_radio[] = { | |||
282 | }; | 282 | }; |
283 | #endif | 283 | #endif |
284 | 284 | ||
285 | #ifdef HAVE_USBSTACK | ||
286 | static const struct button_mapping button_context_usb_hid[] = { | ||
287 | { ACTION_USB_HID_PLAY, BUTTON_VIEW, BUTTON_NONE }, | ||
288 | { ACTION_USB_HID_STOP, BUTTON_POWER, BUTTON_NONE }, | ||
289 | { ACTION_USB_HID_SKIPPREV, BUTTON_LEFT, BUTTON_NONE }, | ||
290 | { ACTION_USB_HID_SKIPNEXT, BUTTON_RIGHT, BUTTON_NONE }, | ||
291 | { ACTION_USB_HID_VOLUP, BUTTON_UP, BUTTON_NONE }, | ||
292 | { ACTION_USB_HID_VOLUP, BUTTON_UP|BUTTON_REPEAT, BUTTON_NONE }, | ||
293 | { ACTION_USB_HID_VOLUP, BUTTON_VOL_UP, BUTTON_NONE }, | ||
294 | { ACTION_USB_HID_VOLUP, BUTTON_VOL_UP|BUTTON_REPEAT, BUTTON_NONE }, | ||
295 | { ACTION_USB_HID_VOLDOWN, BUTTON_DOWN, BUTTON_NONE }, | ||
296 | { ACTION_USB_HID_VOLDOWN, BUTTON_DOWN|BUTTON_REPEAT, BUTTON_NONE }, | ||
297 | { ACTION_USB_HID_VOLDOWN, BUTTON_VOL_DOWN, BUTTON_NONE }, | ||
298 | { ACTION_USB_HID_VOLDOWN, BUTTON_VOL_DOWN|BUTTON_REPEAT, BUTTON_NONE }, | ||
299 | { ACTION_USB_HID_MUTE, BUTTON_SELECT, BUTTON_NONE }, | ||
300 | { ACTION_USB_HID_MENU, BUTTON_MENU, BUTTON_NONE }, | ||
301 | |||
302 | LAST_ITEM_IN_LIST | ||
303 | }; /* button_context_usb_hid */ | ||
304 | #endif | ||
305 | |||
285 | const struct button_mapping* get_context_mapping(int context) | 306 | const struct button_mapping* get_context_mapping(int context) |
286 | { | 307 | { |
287 | switch (context) | 308 | switch (context) |
@@ -329,6 +350,10 @@ const struct button_mapping* get_context_mapping(int context) | |||
329 | case CONTEXT_FM: | 350 | case CONTEXT_FM: |
330 | return button_context_radio; | 351 | return button_context_radio; |
331 | #endif | 352 | #endif |
353 | #ifdef HAVE_USBSTACK | ||
354 | case CONTEXT_USB_HID: | ||
355 | return button_context_usb_hid; | ||
356 | #endif | ||
332 | } | 357 | } |
333 | return button_context_standard; | 358 | return button_context_standard; |
334 | } | 359 | } |