summaryrefslogtreecommitdiff
path: root/apps/menu.h
diff options
context:
space:
mode:
authorWilliam Wilgus <me.theuser@yahoo.com>2019-09-20 03:07:29 -0500
committerWilliam Wilgus <me.theuser@yahoo.com>2019-09-20 03:07:29 -0500
commit10e5e56f3c62383afba30b553fac1ee624a8428d (patch)
tree4431aa03b77fb7724933c8ac21c53a26d545f869 /apps/menu.h
parentd0883d747ab7eb7a26364f01d2ab2f5445fbc204 (diff)
downloadrockbox-10e5e56f3c62383afba30b553fac1ee624a8428d.tar.gz
rockbox-10e5e56f3c62383afba30b553fac1ee624a8428d.zip
Bug fix dynamic menus
Dynamic menus had a buffer_len variable in the parent function but it was discarded before passing to the callbacks Why!!?? No clue but everything that used it was assuming MAXPATH Wouldn't be surprised to see some bugs pop out from this one.. init_menu_lists() was assuming MENU_HAS_DESC and setting the menu title + icon based on such even though it could be invalid didn't see anywhere in the code that was currently using MENU_DYNAMIC_DESC in relation to a top level menu but considering it caused all kinds of corruption to the menu when I tried its probably been tried and abandoned before... Change-Id: I8d961d748918bfa8ea6adb5ad60491af4d739d6e
Diffstat (limited to 'apps/menu.h')
-rw-r--r--apps/menu.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/apps/menu.h b/apps/menu.h
index df5f7ced9f..7ace51329f 100644
--- a/apps/menu.h
+++ b/apps/menu.h
@@ -91,7 +91,8 @@ struct menu_item_ex {
91 const struct menu_get_name_and_icon { 91 const struct menu_get_name_and_icon {
92 int (*menu_callback)(int action, 92 int (*menu_callback)(int action,
93 const struct menu_item_ex *this_item); 93 const struct menu_item_ex *this_item);
94 char *(*list_get_name)(int selected_item, void * data, char *buffer); 94 char *(*list_get_name)(int selected_item, void * data,
95 char *buffer, size_t buffer_len);
95 int (*list_speak_item)(int selected_item, void * data); 96 int (*list_speak_item)(int selected_item, void * data);
96 void *list_get_name_data; 97 void *list_get_name_data;
97 int icon_id; 98 int icon_id;