Lines Matching refs:menu

5  * Introduced single menu mode (show all sub-menus in one large tree).
60 "o To exit a menu use the cursor keys to highlight the <Exit> button\n"
149 "If you prefer to have all of the options listed in a single menu,\n"
182 "Arrow keys navigate the menu. "
256 "o The line 'Prompt:' shows the text used in the menu structure for\n"
261 " this symbol to be visible in the menu (selectable)\n"
262 "o The 'Location:' lines tells where in the menu structure this symbol\n"
265 " selectable menu item - and the current value is displayed inside\n"
269 " after exiting this new menu.\n"
283 static struct menu *current_menu;
291 static void conf(struct menu *menu, struct menu *active_menu);
370 static void show_help(struct menu *menu)
375 menu_get_ext_help(menu, &help);
377 show_helptext(menu_get_prompt(menu), str_get(&help));
383 struct menu *target;
504 static void build_conf(struct menu *menu)
508 struct menu *child;
518 visible = menu_is_visible(menu);
519 if (show_all_options && !menu_has_prompt(menu))
524 sym = menu->sym;
525 prop = menu->prompt;
527 if (prop && menu != current_menu) {
528 const char *prompt = menu_get_prompt(menu);
534 menu->data ? "-->" : "++>",
539 menu_is_empty(menu) ? "----" : "--->");
541 item_set_data(menu);
542 if (single_menu_mode && menu->data)
550 item_set_data(menu);
558 item_set_data(menu);
569 struct menu *def_menu = NULL;
572 for (child = menu->list; child; child = child->next) {
593 item_set_data(menu);
597 item_set_data(menu);
600 item_add_str("%*c%s", indent + 1, ' ', menu_get_prompt(menu));
614 if (menu == current_menu) {
615 item_make("---%*c%s", indent + 1, ' ', menu_get_prompt(menu));
617 item_set_data(menu);
625 item_set_data(menu);
634 item_set_data(menu);
650 item_set_data(menu);
658 item_add_str("%*c%s%s", tmp, ' ', menu_get_prompt(menu),
662 item_set_data(menu);
666 item_add_str("%*c%s%s", indent + 1, ' ', menu_get_prompt(menu),
669 if (menu->prompt->type == P_MENU) {
670 item_add_str(" %s", menu_is_empty(menu) ? "----" : "--->");
677 for (child = menu->list; child; child = child->next)
682 static void conf_choice(struct menu *menu)
684 const char *prompt = menu_get_prompt(menu);
685 struct menu *child;
688 active = sym_get_choice_value(menu->sym);
694 current_menu = menu;
695 for (child = menu->list; child; child = child->next) {
707 if (child->sym == sym_get_choice_value(menu->sym))
733 show_help(menu);
743 static void conf_string(struct menu *menu)
745 const char *prompt = menu_get_prompt(menu);
751 switch (sym_get_type(menu->sym)) {
767 sym_get_string_value(menu->sym));
770 if (sym_set_string_value(menu->sym, dialog_input_result))
775 show_help(menu);
837 static void conf(struct menu *menu, struct menu *active_menu)
839 struct menu *submenu;
840 const char *prompt = menu_get_prompt(menu);
846 if (menu != &rootmenu)
847 stpart.text = menu_get_prompt(menu);
854 current_menu = menu;
855 build_conf(menu);