Add new actions to %Tp (Touchscreen areas)
Add the following actions to %Tp: createbookmark create a new bookmark from the wps listbookmarks list bookmarks from the wps trackinfo show track info from the wps My main motivation was to allow bookmarking and jumping around audio books from the wps on touch enabled targets. You can do it now through the context menu but it requires 4 screen presses instead of 1. Change-Id: I1fa1bf0064dfd22b897eca7c56acc1ce8956f14c Reviewed-on: http://gerrit.rockbox.org/171 Reviewed-by: Jonathan Gordon <rockbox@jdgordon.info>
This commit is contained in:
parent
47e30b8cdc
commit
595427c095
4 changed files with 31 additions and 8 deletions
|
@ -129,6 +129,8 @@ enum {
|
||||||
ACTION_WPS_QUICKSCREEN,/* optional */
|
ACTION_WPS_QUICKSCREEN,/* optional */
|
||||||
ACTION_WPS_MENU, /*this should be the same as ACTION_STD_MENU */
|
ACTION_WPS_MENU, /*this should be the same as ACTION_STD_MENU */
|
||||||
ACTION_WPS_VIEW_PLAYLIST,
|
ACTION_WPS_VIEW_PLAYLIST,
|
||||||
|
ACTION_WPS_LIST_BOOKMARKS,/* optional */
|
||||||
|
ACTION_WPS_CREATE_BOOKMARK,/* optional */
|
||||||
ACTION_WPS_REC,
|
ACTION_WPS_REC,
|
||||||
#if 0
|
#if 0
|
||||||
ACTION_WPSAB_SINGLE, /* This needs to be #defined in
|
ACTION_WPSAB_SINGLE, /* This needs to be #defined in
|
||||||
|
|
|
@ -1287,7 +1287,10 @@ static const struct touchaction touchactions[] = {
|
||||||
{"browse", ACTION_WPS_BROWSE },
|
{"browse", ACTION_WPS_BROWSE },
|
||||||
{"play", ACTION_WPS_PLAY }, {"stop", ACTION_WPS_STOP },
|
{"play", ACTION_WPS_PLAY }, {"stop", ACTION_WPS_STOP },
|
||||||
{"shuffle", ACTION_TOUCH_SHUFFLE }, {"repmode", ACTION_TOUCH_REPMODE },
|
{"shuffle", ACTION_TOUCH_SHUFFLE }, {"repmode", ACTION_TOUCH_REPMODE },
|
||||||
{"pitch", ACTION_WPS_PITCHSCREEN}, {"playlist", ACTION_WPS_VIEW_PLAYLIST },
|
{"pitch", ACTION_WPS_PITCHSCREEN}, {"trackinfo", ACTION_WPS_ID3SCREEN },
|
||||||
|
{"playlist", ACTION_WPS_VIEW_PLAYLIST },
|
||||||
|
{"listbookmarks", ACTION_WPS_LIST_BOOKMARKS },
|
||||||
|
{"createbookmark", ACTION_WPS_CREATE_BOOKMARK },
|
||||||
|
|
||||||
#if CONFIG_TUNER
|
#if CONFIG_TUNER
|
||||||
/* FM screen actions */
|
/* FM screen actions */
|
||||||
|
|
|
@ -1042,6 +1042,21 @@ long gui_wps_show(void)
|
||||||
exit = true;
|
exit = true;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
case ACTION_WPS_LIST_BOOKMARKS:
|
||||||
|
gwps_leave_wps();
|
||||||
|
if (bookmark_load_menu() == BOOKMARK_USB_CONNECTED)
|
||||||
|
{
|
||||||
|
return GO_TO_ROOT;
|
||||||
|
}
|
||||||
|
restore = true;
|
||||||
|
break;
|
||||||
|
|
||||||
|
case ACTION_WPS_CREATE_BOOKMARK:
|
||||||
|
gwps_leave_wps();
|
||||||
|
bookmark_create_menu();
|
||||||
|
restore = true;
|
||||||
|
break;
|
||||||
|
|
||||||
case ACTION_WPS_ID3SCREEN:
|
case ACTION_WPS_ID3SCREEN:
|
||||||
{
|
{
|
||||||
gwps_leave_wps();
|
gwps_leave_wps();
|
||||||
|
|
|
@ -657,19 +657,22 @@ display cycling round the defined sublines. See
|
||||||
\item[wps\_next] -- Next track.
|
\item[wps\_next] -- Next track.
|
||||||
\item[ffwd] -- Seek forwards in the track.
|
\item[ffwd] -- Seek forwards in the track.
|
||||||
\item[rwd] -- Seek backwards in the track.
|
\item[rwd] -- Seek backwards in the track.
|
||||||
\item[menu] -- Go to the main menu.
|
\item[progressbar] -- Seek to the appropriate position in the track based on the touch.
|
||||||
\item[browse] -- Go back to the file browser or database.
|
|
||||||
\item[shuffle] -- Toggle shuffle mode.
|
\item[shuffle] -- Toggle shuffle mode.
|
||||||
\item[repmode] -- Cycle through the repeat modes.
|
\item[repmode] -- Cycle through the repeat modes.
|
||||||
\item[quickscreen] -- Go to the quickscreen.
|
|
||||||
\item[contextmenu] -- Open the context menu.
|
|
||||||
\item[playlist] -- Go to the playlist viewer.
|
|
||||||
\item[progressbar] -- Seek to the appropriate position in the track based on the touch.
|
|
||||||
\item[volume] -- Set the volume to the appropriate level based on the touch.
|
\item[volume] -- Set the volume to the appropriate level based on the touch.
|
||||||
\item[pitch] -- Open the pitchscreen.
|
|
||||||
\item[voldown] -- Decrease the volume by one step.
|
\item[voldown] -- Decrease the volume by one step.
|
||||||
\item[volup] -- Increase the volume by one step.
|
\item[volup] -- Increase the volume by one step.
|
||||||
\item[mute] -- Un/Mute playback.
|
\item[mute] -- Un/Mute playback.
|
||||||
|
\item[createbookmark] -- Create a bookmark in the currently-playing track.
|
||||||
|
\item[menu] -- Go to the main menu.
|
||||||
|
\item[browse] -- Go back to the file browser or database.
|
||||||
|
\item[quickscreen] -- Go to the quickscreen.
|
||||||
|
\item[contextmenu] -- Open the context menu.
|
||||||
|
\item[playlist] -- Go to the playlist viewer.
|
||||||
|
\item[listbookmarks] -- List the bookmarks for the currently-playing directory or playlist.
|
||||||
|
\item[trackinfo] -- Open the track info viewer.
|
||||||
|
\item[pitch] -- Open the pitchscreen.
|
||||||
\item[setting\_inc] -- Increment the subsequently specified setting (e.g
|
\item[setting\_inc] -- Increment the subsequently specified setting (e.g
|
||||||
\config{\%T(0,0, setting\_inc, volume)} increases the volume by one step).
|
\config{\%T(0,0, setting\_inc, volume)} increases the volume by one step).
|
||||||
\item[setting\_dec] -- Decrement the subsequently specified setting (e.g
|
\item[setting\_dec] -- Decrement the subsequently specified setting (e.g
|
||||||
|
|
Loading…
Reference in a new issue