diff options
| author | Linus Nielsen Feltzing <linus@haxx.se> | 2007-02-16 10:40:59 +0000 |
|---|---|---|
| committer | Linus Nielsen Feltzing <linus@haxx.se> | 2007-02-16 10:40:59 +0000 |
| commit | 6ffd8043cbdbf6c092ac7eb689863a02dc9840ff (patch) | |
| tree | 3a9e3458ad15fdb73de8c9b6e435bbe0ef0576bc /apps | |
| parent | 750fa4a1a0eb3671b7bd73ba3cb7629b437f8fe5 (diff) | |
| download | rockbox-6ffd8043cbdbf6c092ac7eb689863a02dc9840ff.zip rockbox-6ffd8043cbdbf6c092ac7eb689863a02dc9840ff.tar.gz rockbox-6ffd8043cbdbf6c092ac7eb689863a02dc9840ff.tar.bz2 rockbox-6ffd8043cbdbf6c092ac7eb689863a02dc9840ff.tar.xz | |
Removed some unused menu code
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@12335 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps')
| -rw-r--r-- | apps/menu.c | 49 | ||||
| -rw-r--r-- | apps/plugin.c | 2 | ||||
| -rw-r--r-- | apps/plugin.h | 6 |
3 files changed, 4 insertions, 53 deletions
diff --git a/apps/menu.c b/apps/menu.c index 88574ca..523a92e 100644 --- a/apps/menu.c +++ b/apps/menu.c @@ -253,51 +253,6 @@ int menu_count(int menu) } /* - * Allows a menu item at the current cursor position in "menu" - * to be moved up the list - */ - -bool menu_moveup(int menu) -{ - struct menu_item swap; - int selected=menu_cursor(menu); - /* can't be the first item ! */ - if( selected == 0) - return false; - - /* use a temporary variable to do the swap */ - swap = menus[menu].items[selected - 1]; - menus[menu].items[selected - 1] = menus[menu].items[selected]; - menus[menu].items[selected] = swap; - - gui_synclist_select_previous(&(menus[menu].synclist)); - return true; -} - -/* - * Allows a menu item at the current cursor position in "menu" to be moved down the list - */ - -bool menu_movedown(int menu) -{ - struct menu_item swap; - int selected=menu_cursor(menu); - int nb_items=gui_synclist_get_nb_items(&(menus[menu].synclist)); - - /* can't be the last item ! */ - if( selected == nb_items - 1) - return false; - - /* use a temporary variable to do the swap */ - swap = menus[menu].items[selected + 1]; - menus[menu].items[selected + 1] = menus[menu].items[selected]; - menus[menu].items[selected] = swap; - - gui_synclist_select_next(&(menus[menu].synclist)); - return true; -} - -/* * Allows to set the cursor position. Doesn't redraw by itself. */ @@ -530,8 +485,8 @@ int do_menu(const struct menu_item_ex *start_menu) else if ((action == ACTION_STD_CANCEL) || (action == ACTION_STD_MENU)) { - if (in_stringlist) - in_stringlist = false; + in_stringlist = false; + if (stack_top > 0) { get_menu_callback(menu,&menu_callback); diff --git a/apps/plugin.c b/apps/plugin.c index e11fd5c..dd82a8d 100644 --- a/apps/plugin.c +++ b/apps/plugin.c @@ -386,8 +386,6 @@ static const struct plugin_api rockbox_api = { menu_description, menu_delete, menu_count, - menu_moveup, - menu_movedown, menu_draw, menu_insert, menu_set_cursor, diff --git a/apps/plugin.h b/apps/plugin.h index 00c4326..daab88e 100644 --- a/apps/plugin.h +++ b/apps/plugin.h @@ -110,12 +110,12 @@ #define PLUGIN_MAGIC 0x526F634B /* RocK */ /* increase this every time the api struct changes */ -#define PLUGIN_API_VERSION 43 +#define PLUGIN_API_VERSION 44 /* update this to latest version if a change to the api struct breaks backwards compatibility (and please take the opportunity to sort in any new function which are "waiting" at the end of the function table) */ -#define PLUGIN_MIN_API_VERSION 43 +#define PLUGIN_MIN_API_VERSION 44 /* plugin return codes */ enum plugin_status { @@ -484,8 +484,6 @@ struct plugin_api { char* (*menu_description)(int menu, int position); void (*menu_delete)(int menu, int position); int (*menu_count)(int menu); - bool (*menu_moveup)(int menu); - bool (*menu_movedown)(int menu); void (*menu_draw)(int menu); void (*menu_insert)(int menu, int position, char *desc, bool (*function) (void)); void (*menu_set_cursor)(int menu, int position); |