Home
last modified time | relevance | path

Searched refs:max_choice (Results 1 – 3 of 3) sorted by relevance

/external/toybox/kconfig/lxdialog/
Dmenubox.c188 int first_item = 0, max_choice; in dialog_menu() local
201 max_choice = MIN(menu_height, item_count()); in dialog_menu()
251 if ((scroll <= choice) && (scroll + max_choice > choice) && in dialog_menu()
252 (scroll >= 0) && (scroll + max_choice <= item_count())) { in dialog_menu()
258 if ((choice >= max_choice)) { in dialog_menu()
259 if (choice >= item_count() - max_choice / 2) in dialog_menu()
260 scroll = first_item = item_count() - max_choice; in dialog_menu()
262 scroll = first_item = choice - max_choice / 2; in dialog_menu()
267 for (i = 0; i < max_choice; i++) { in dialog_menu()
287 i = max_choice; in dialog_menu()
[all …]
Dchecklist.c115 int key = 0, button = 0, choice = 0, scroll = 0, max_choice; in dialog_checklist() local
134 max_choice = MIN(list_height, item_count()); in dialog_checklist()
187 for (i = 0; i < max_choice; i++) { in dialog_checklist()
204 for (i = 0; i < max_choice; i++) { in dialog_checklist()
210 if (i < max_choice || key == KEY_UP || key == KEY_DOWN || in dialog_checklist()
238 if (choice == max_choice - 1) { in dialog_checklist()
244 item_set(scroll + max_choice - 1); in dialog_checklist()
246 max_choice - 1, in dialog_checklist()
253 item_set(scroll + max_choice - 1); in dialog_checklist()
254 print_item(list, max_choice - 1, TRUE); in dialog_checklist()
/external/autotest/utils/frozen_chromite/lib/
Dcros_build_lib.py1306 def PromptForChoice(max_choice, more): argument
1307 prompt = 'Please choose an option [0-%d]' % max_choice
1321 if choice < 0 or choice > max_choice:
1322 print('Choice %d out of range (0-%d)' % (choice, max_choice))
1327 max_choice = 0
1334 max_choice = i
1336 return PromptForChoice(max_choice, False)