From 680acbf71ba6972c4690a340f6464dcc44e48b88 Mon Sep 17 00:00:00 2001 From: Jonathan Gordon Date: Wed, 25 Apr 2007 10:41:17 +0000 Subject: fix a stupid bug which didnt check the flag correctly (caused the player to crash trying to access the shutdown options context menu) git-svn-id: svn://svn.rockbox.org/rockbox/trunk@13258 a1c6a512-1295-4272-9138-f99709370657 --- apps/root_menu.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'apps') diff --git a/apps/root_menu.c b/apps/root_menu.c index b51c3aeed7..9f1491df8e 100644 --- a/apps/root_menu.c +++ b/apps/root_menu.c @@ -377,7 +377,7 @@ static int get_selection(int last_screen) unsigned int i; for(i=0; i< sizeof(root_menu__)/sizeof(*root_menu__); i++) { - if ((root_menu__[i]->flags&MT_RETURN_VALUE) && + if (((root_menu__[i]->flags&MENU_TYPE_MASK) == MT_RETURN_VALUE) && (root_menu__[i]->value == last_screen)) { return i; @@ -408,7 +408,7 @@ static inline int load_screen(int screen) static int load_context_screen(int selection) { const struct menu_item_ex *context_menu = NULL; - if (root_menu__[selection]->flags&MT_RETURN_VALUE) + if ((root_menu__[selection]->flags&MENU_TYPE_MASK) == MT_RETURN_VALUE) { int item = root_menu__[selection]->value; context_menu = items[item].context_menu; -- cgit v1.2.3