diff options
author | James D. Smith <smithjd15@gmail.com> | 2021-09-19 00:49:42 -0600 |
---|---|---|
committer | Solomon Peachy <pizza@shaftnet.org> | 2021-09-19 21:05:38 -0400 |
commit | 67716c6b46a7780bff6b80408b3452c01bfbfdc4 (patch) | |
tree | 9f75c9383fb5b7ec108aa0f2860d58d4cc575e84 /apps | |
parent | 5312fe6bdabf54517cc3e2024ab11c74902f6a7f (diff) |
Playlist Viewer: Add file properties to playlist entry menu.
Change-Id: I8fb0da7d117e4a011345bae7f6137ab3253fea4f
Diffstat (limited to 'apps')
-rw-r--r-- | apps/playlist_viewer.c | 16 |
1 files changed, 12 insertions, 4 deletions
diff --git a/apps/playlist_viewer.c b/apps/playlist_viewer.c index e0e2e787cd..07773b90e2 100644 --- a/apps/playlist_viewer.c +++ b/apps/playlist_viewer.c @@ -489,8 +489,8 @@ static int onplay_menu(int index) playlist_buffer_get_track(&viewer.buffer, index); MENUITEM_STRINGLIST(menu_items, ID2P(LANG_PLAYLIST), NULL, ID2P(LANG_CURRENT_PLAYLIST), ID2P(LANG_CATALOG), - ID2P(LANG_REMOVE), ID2P(LANG_MOVE), ID2P(LANG_SHUFFLE), - ID2P(LANG_SAVE), + ID2P(LANG_REMOVE), ID2P(LANG_MOVE), ID2P(LANG_PROPERTIES), + ID2P(LANG_SHUFFLE), ID2P(LANG_SAVE), ID2P(LANG_PLAYLISTVIEWER_SETTINGS)); bool current = (current_track->index == viewer.current_playing_track); @@ -547,16 +547,24 @@ static int onplay_menu(int index) ret = 0; break; case 4: + /* file properties */ + struct playlist_track_info info; + playlist_get_track_info(viewer.playlist, current_track->index, &info); + + result = filetype_load_plugin((void *)"properties", info.filename); + ret = (result == MENU_ATTACHED_USB) ? -1 : 0; + break; + case 5: /* shuffle */ playlist_randomise(viewer.playlist, current_tick, false); ret = 1; break; - case 5: + case 6: /* save playlist */ save_playlist_screen(viewer.playlist); ret = 0; break; - case 6: + case 7: /* playlist viewer settings */ result = do_menu(&viewer_settings_menu, NULL, NULL, false); ret = (result == MENU_ATTACHED_USB) ? -1 : 0; |