Lines Matching refs:menu
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) in show_help() argument
375 menu_get_ext_help(menu, &help); in show_help()
377 show_helptext(menu_get_prompt(menu), str_get(&help)); in show_help()
383 struct menu *target;
504 static void build_conf(struct menu *menu) in build_conf() argument
508 struct menu *child; in build_conf()
518 visible = menu_is_visible(menu); in build_conf()
519 if (show_all_options && !menu_has_prompt(menu)) in build_conf()
524 sym = menu->sym; in build_conf()
525 prop = menu->prompt; in build_conf()
527 if (prop && menu != current_menu) { in build_conf()
528 const char *prompt = menu_get_prompt(menu); in build_conf()
534 menu->data ? "-->" : "++>", in build_conf()
539 menu_is_empty(menu) ? "----" : "--->"); in build_conf()
541 item_set_data(menu); in build_conf()
542 if (single_menu_mode && menu->data) in build_conf()
550 item_set_data(menu); in build_conf()
558 item_set_data(menu); in build_conf()
569 struct menu *def_menu = NULL; in build_conf()
572 for (child = menu->list; child; child = child->next) { in build_conf()
593 item_set_data(menu); in build_conf()
597 item_set_data(menu); in build_conf()
600 item_add_str("%*c%s", indent + 1, ' ', menu_get_prompt(menu)); in build_conf()
614 if (menu == current_menu) { in build_conf()
615 item_make("---%*c%s", indent + 1, ' ', menu_get_prompt(menu)); in build_conf()
617 item_set_data(menu); in build_conf()
625 item_set_data(menu); in build_conf()
634 item_set_data(menu); in build_conf()
650 item_set_data(menu); in build_conf()
658 item_add_str("%*c%s%s", tmp, ' ', menu_get_prompt(menu), in build_conf()
662 item_set_data(menu); in build_conf()
666 item_add_str("%*c%s%s", indent + 1, ' ', menu_get_prompt(menu), in build_conf()
669 if (menu->prompt->type == P_MENU) { in build_conf()
670 item_add_str(" %s", menu_is_empty(menu) ? "----" : "--->"); in build_conf()
677 for (child = menu->list; child; child = child->next) in build_conf()
682 static void conf_choice(struct menu *menu) in conf_choice() argument
684 const char *prompt = menu_get_prompt(menu); in conf_choice()
685 struct menu *child; in conf_choice()
688 active = sym_get_choice_value(menu->sym); in conf_choice()
694 current_menu = menu; in conf_choice()
695 for (child = menu->list; child; child = child->next) { in conf_choice()
707 if (child->sym == sym_get_choice_value(menu->sym)) in conf_choice()
733 show_help(menu); in conf_choice()
743 static void conf_string(struct menu *menu) in conf_string() argument
745 const char *prompt = menu_get_prompt(menu); in conf_string()
751 switch (sym_get_type(menu->sym)) { in conf_string()
767 sym_get_string_value(menu->sym)); in conf_string()
770 if (sym_set_string_value(menu->sym, dialog_input_result)) in conf_string()
775 show_help(menu); in conf_string()
837 static void conf(struct menu *menu, struct menu *active_menu) in conf() argument
839 struct menu *submenu; in conf()
840 const char *prompt = menu_get_prompt(menu); in conf()
846 if (menu != &rootmenu) in conf()
847 stpart.text = menu_get_prompt(menu); in conf()
854 current_menu = menu; in conf()
855 build_conf(menu); in conf()