diff options
Diffstat (limited to 'apps/onplay.c')
-rw-r--r-- | apps/onplay.c | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/apps/onplay.c b/apps/onplay.c index d177fac2c4..61bfe66957 100644 --- a/apps/onplay.c +++ b/apps/onplay.c | |||
@@ -1368,6 +1368,7 @@ int onplay(char* file, int attr, int from, bool hotkey) | |||
1368 | context = from; | 1368 | context = from; |
1369 | selected_file = file; | 1369 | selected_file = file; |
1370 | selected_file_attr = attr; | 1370 | selected_file_attr = attr; |
1371 | int menu_selection; | ||
1371 | #ifdef HAVE_HOTKEY | 1372 | #ifdef HAVE_HOTKEY |
1372 | if (hotkey) | 1373 | if (hotkey) |
1373 | return execute_hotkey(context == CONTEXT_WPS); | 1374 | return execute_hotkey(context == CONTEXT_WPS); |
@@ -1379,13 +1380,17 @@ int onplay(char* file, int attr, int from, bool hotkey) | |||
1379 | menu = &wps_onplay_menu; | 1380 | menu = &wps_onplay_menu; |
1380 | else | 1381 | else |
1381 | menu = &tree_onplay_menu; | 1382 | menu = &tree_onplay_menu; |
1382 | switch (do_menu(menu, NULL, NULL, false)) | 1383 | menu_selection = do_menu(menu, NULL, NULL, false); |
1383 | { | ||
1384 | #ifdef HAVE_HOTKEY | 1384 | #ifdef HAVE_HOTKEY |
1385 | hotkey_settable_menu = false; | 1385 | hotkey_settable_menu = false; |
1386 | switch (menu_selection) | ||
1387 | { | ||
1386 | case MENU_SELECTED_HOTKEY: | 1388 | case MENU_SELECTED_HOTKEY: |
1387 | set_hotkey(context == CONTEXT_WPS); | 1389 | set_hotkey(context == CONTEXT_WPS); |
1388 | return ONPLAY_RELOAD_DIR; | 1390 | return ONPLAY_RELOAD_DIR; |
1391 | #else | ||
1392 | switch (menu_selection) | ||
1393 | { | ||
1389 | #endif | 1394 | #endif |
1390 | case GO_TO_WPS: | 1395 | case GO_TO_WPS: |
1391 | return ONPLAY_START_PLAY; | 1396 | return ONPLAY_START_PLAY; |