summaryrefslogtreecommitdiffstats
path: root/apps
diff options
context:
space:
mode:
authorRichard Quirk <richard.quirk@gmail.com>2013-03-05 19:31:36 +0100
committerJonathan Gordon <rockbox@jdgordon.info>2013-04-06 11:35:36 +0200
commitdcba74155e96ef8e6da757cba239241469b5859a (patch)
treec0945c7f7330ff10e8f22b7d87b5aa46a1cf15b5 /apps
parent703bc407b4565736eb1c40f85887c84c33e37696 (diff)
downloadrockbox-dcba74155e96ef8e6da757cba239241469b5859a.tar.gz
rockbox-dcba74155e96ef8e6da757cba239241469b5859a.zip
bookmark: add cancelling of autoload bookmark
When autoload bookmark is set to "Ask", navigate to a file with bookmarks in that directory. Select the file and the bookmark list appears. Even if you chose to cancel, the track started prior to this patch. Change-Id: I453999a9bc20faae97f9cf2080ef613c602ad8e1 Reviewed-on: http://gerrit.rockbox.org/416 Reviewed-by: Jonathan Gordon <rockbox@jdgordon.info>
Diffstat (limited to 'apps')
-rw-r--r--apps/bookmark.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/apps/bookmark.c b/apps/bookmark.c
index 12ec1edd0f..543e89331a 100644
--- a/apps/bookmark.c
+++ b/apps/bookmark.c
@@ -435,7 +435,7 @@ bool bookmark_autoload(const char* file)
}
else
{
- select_bookmark(global_bookmark_file_name, true, &bookmark);
+ int ret = select_bookmark(global_bookmark_file_name, true, &bookmark);
if (bookmark != NULL)
{
@@ -451,7 +451,7 @@ bool bookmark_autoload(const char* file)
return true;
}
- return false;
+ return ret != BOOKMARK_SUCCESS;
}
}
@@ -801,8 +801,9 @@ static int select_bookmark(const char* bookmark_file_name, bool show_dont_resume
*selected_bookmark = bookmarks->items[item - bookmarks->start];
return BOOKMARK_SUCCESS;
}
-
- /* Else fall through */
+ exit = true;
+ ret = BOOKMARK_SUCCESS;
+ break;
case ACTION_TREE_WPS:
case ACTION_STD_CANCEL: