summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorOsborne Jacobs <ozziejacks@gmail.com>2012-03-02 23:30:07 -0500
committerJonathan Gordon <rockbox@jdgordon.info>2012-03-03 10:45:51 +0100
commitd5e676ba29c112ff170402df0352a43416b82690 (patch)
tree3391689e654fe415e1edef752682404fe51085b6
parentbcfa783100529ffbd29c6f0a7a9275c27df5cf66 (diff)
downloadrockbox-d5e676ba29c112ff170402df0352a43416b82690.zip
rockbox-d5e676ba29c112ff170402df0352a43416b82690.tar.gz
rockbox-d5e676ba29c112ff170402df0352a43416b82690.tar.bz2
rockbox-d5e676ba29c112ff170402df0352a43416b82690.tar.xz
Add a %cs(current screen) state for the "Track Info" screen
Added a new state (current activity) to the %cs tag for the Track Info screen. This will allow the Track Info screen to be detectable when skinning using sbs files. Change-Id: I9319ebce2f8e64b0c974f4a6e3b44f9accee32c5 Reviewed-on: http://gerrit.rockbox.org/170 Reviewed-by: Jonathan Gordon <rockbox@jdgordon.info>
-rw-r--r--apps/misc.h3
-rw-r--r--apps/screens.c15
2 files changed, 15 insertions, 3 deletions
diff --git a/apps/misc.h b/apps/misc.h
index a41a831..a3d9ffd 100644
--- a/apps/misc.h
+++ b/apps/misc.h
@@ -127,7 +127,8 @@ enum current_activity {
ACTIVITY_SYSTEMSCREEN,
ACTIVITY_TIMEDATESCREEN,
ACTIVITY_BOOKMARKSLIST,
- ACTIVITY_SHORTCUTSMENU
+ ACTIVITY_SHORTCUTSMENU,
+ ACTIVITY_ID3SCREEN
};
#if CONFIG_CODEC == SWCODEC
diff --git a/apps/screens.c b/apps/screens.c
index 8d4585f..866ec58 100644
--- a/apps/screens.c
+++ b/apps/screens.c
@@ -767,6 +767,8 @@ bool browse_id3(void)
struct id3view_info info;
info.count = 0;
info.id3 = id3;
+ bool ret = false;
+ push_current_activity(ACTIVITY_ID3SCREEN);
for (i = 0; i < ARRAYLEN(id3_headers); i++)
{
char temp[8];
@@ -783,12 +785,21 @@ bool browse_id3(void)
if(!gui_synclist_do_button(&id3_lists, &key,LIST_WRAP_UNLESS_HELD))
{
if (key == ACTION_STD_OK || key == ACTION_STD_CANCEL)
- return false;
+ {
+ ret = false;
+ break;
+ }
else if (key == ACTION_STD_MENU ||
default_event_handler(key) == SYS_USB_CONNECTED)
- return true;
+ {
+ ret = true;
+ break;
+ }
}
}
+
+ pop_current_activity();
+ return ret;
}
static const char* runtime_get_data(int selected_item, void* data,