Rockbox open source high quality audio player as a Music Player Daemon
mpris rockbox mpd libadwaita audio rust zig deno
2
fork

Configure Feed

Select the types of activity you want to include in your feed.

wps: Replace menu items "Open With" & "Delete" with "Show in Files"

Limit these (less commonly used) "file handling" operations
to the File Browser while making it quicker to reveal the
file that is currently playing from the WPS.

"Open With" and "Delete" remain available as WPS shortcuts.

Change-Id: I91e582a45998160f07a3f7e16d475d770e8c5212

authored by

Christian Soffke and committed by
Solomon Peachy
e405858b e85f1201

+54 -12
+2
apps/gui/wps.c
··· 829 829 if (retval == ONPLAY_MAINMENU 830 830 || !audio_status()) 831 831 return GO_TO_ROOT; 832 + else if (retval == ONPLAY_REVEAL_FILE) 833 + return GO_TO_FILEBROWSER; 832 834 else if (retval == ONPLAY_PLAYLIST) 833 835 return GO_TO_PLAYLIST_VIEWER; 834 836 else if (retval == ONPLAY_PLUGIN)
+28
apps/lang/english.lang
··· 17057 17057 *: "U S B" 17058 17058 </voice> 17059 17059 </phrase> 17060 + <phrase> 17061 + id: LANG_FILE_NOT_FOUND 17062 + desc: When file does not exist 17063 + user: core 17064 + <source> 17065 + *: "File not found" 17066 + </source> 17067 + <dest> 17068 + *: "File not found" 17069 + </dest> 17070 + <voice> 17071 + *: "File not found" 17072 + </voice> 17073 + </phrase> 17074 + <phrase> 17075 + id: LANG_SHOW_IN_FILES 17076 + desc: Reveal item in File Browser 17077 + user: core 17078 + <source> 17079 + *: "Show in Files" 17080 + </source> 17081 + <dest> 17082 + *: "Show in Files" 17083 + </dest> 17084 + <voice> 17085 + *: "Show in Files" 17086 + </voice> 17087 + </phrase>
+18 -2
apps/onplay.c
··· 897 897 return false; 898 898 } 899 899 900 + static int reveal(void) 901 + { 902 + if (!file_exists(selected_file.path)) 903 + { 904 + splash(HZ*2, ID2P(LANG_FILE_NOT_FOUND)); 905 + return 0; 906 + } 907 + 908 + strmemccpy(global_status.browse_last_folder, selected_file.path, 909 + sizeof global_status.browse_last_folder); 910 + onplay_result = ONPLAY_REVEAL_FILE; 911 + return 0; 912 + } 913 + 914 + MENUITEM_FUNCTION(reveal_item, 0, ID2P(LANG_SHOW_IN_FILES), 915 + reveal, NULL, Icon_file_view_menu); 900 916 MENUITEM_FUNCTION(list_viewers_item, 0, ID2P(LANG_ONPLAY_OPEN_WITH), 901 917 list_viewers, clipboard_callback, Icon_NOICON); 902 918 MENUITEM_FUNCTION_W_PARAM(properties_item, 0, ID2P(LANG_PROPERTIES), ··· 1124 1140 #endif 1125 1141 &bookmark_menu, 1126 1142 &plugin_item, 1127 - &browse_id3_item, &list_viewers_item, 1128 - &delete_file_item, &view_cue_item, 1143 + &browse_id3_item, 1144 + &reveal_item, &view_cue_item, 1129 1145 #ifdef HAVE_PITCHCONTROL 1130 1146 &pitch_menu, 1131 1147 #endif
+1
apps/onplay.h
··· 38 38 ONPLAY_MAINMENU = -1, 39 39 ONPLAY_OK = 0, 40 40 ONPLAY_RELOAD_DIR, 41 + ONPLAY_REVEAL_FILE, 41 42 ONPLAY_START_PLAY, 42 43 ONPLAY_PLAYLIST, 43 44 ONPLAY_PLUGIN,
+3 -1
manual/rockbox_interface/browsing_and_playing.tex
··· 143 143 Deletes the currently selected file. This option applies only to files, and 144 144 not to directories. Rockbox will ask for confirmation before deleting a file. 145 145 Press \ActionYesNoAccept{} 146 - to confirm deletion or any other key to cancel. 146 + to confirm deletion or any other key to cancel. When deleting a currently 147 + playing file, the part of the file that has already been buffered (i.e. read 148 + into the \daps\ memory) will continue playing. This may even be the whole track. 147 149 \item [Delete Directory.] 148 150 Deletes the currently selected directory and all of the files and subdirectories 149 151 it may contain. Deleted directories cannot be recovered. Use this feature with
+2 -9
manual/rockbox_interface/wps.tex
··· 254 254 \setting{Context Menu}. Then select \setting{Show Track Info}. The same steps 255 255 work in the Playlist Viewer as well.} 256 256 257 - \subsubsection{Open With...} 258 - This \setting{Open With} function is the same as the \setting{Open With} 259 - function in the file browser's \setting{Context Menu}. 260 - 261 - \subsubsection{Delete} 262 - Delete the currently playing file. The file will be deleted but the playback 263 - of the file will not stop immediately. Instead, the part of the file that 264 - has already been buffered (i.e. read into the \daps\ memory) will be played. 265 - This may even be the whole track. 257 + \subsubsection{Show in Files} 258 + Reveal the currently playing track in the \setting{File Browser}. 266 259 267 260 \opt{pitchscreen}{ 268 261 \subsubsection{\label{sec:pitchscreen}Pitch}