From fd9d1401191d3bae99832b3b783a63e26dc706ca Mon Sep 17 00:00:00 2001 From: Jonathan Gordon Date: Sun, 20 May 2007 14:24:02 +0000 Subject: Fix FS#7176 - wps context menu doesnt set the correct selection. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@13445 a1c6a512-1295-4272-9138-f99709370657 --- apps/menu.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/apps/menu.c b/apps/menu.c index 474c1b6886..a29f5d5dde 100644 --- a/apps/menu.c +++ b/apps/menu.c @@ -599,8 +599,17 @@ int do_menu(const struct menu_item_ex *start_menu, int *start_selected) } action_signalscreenchange(); if (start_selected) + { + /* make sure the start_selected variable is set to + the selected item from the menu do_menu() was called from */ + if (stack_top > 0) + { + menu = menu_stack[0]; + init_menu_lists(menu,&lists,menu_stack_selected_item[0],true); + } *start_selected = get_menu_selection( gui_synclist_get_sel_pos(&lists), menu); + } return ret; } -- cgit v1.2.3