menu: Add support for user defined item choice function
[oweals/u-boot.git] / include / menu.h
index 7af5fdb0edfa4302b3162f75518d02c63921ddb3..f4dd5af165f10b2d9c0988762f14bfbbdae61c72 100644 (file)
@@ -21,7 +21,9 @@
 struct menu;
 
 struct menu *menu_create(char *title, int timeout, int prompt,
-                               void (*item_data_print)(void *));
+                               void (*item_data_print)(void *),
+                               char *(*item_choice)(void *),
+                               void *item_choice_data);
 int menu_default_set(struct menu *m, char *item_key);
 int menu_get_choice(struct menu *m, void **choice);
 int menu_item_add(struct menu *m, char *item_key, void *item_data);