Lines Matching refs:choice
102 #define print_item(index, choice, selected) \
105 do_print_item(menu, item_str(), choice, selected, !item_is_tag(':')); \
187 int key = 0, button = 0, scroll = 0, choice = 0;
245 /* Set choice to default item */
248 choice = item_n();
251 if ((scroll <= choice) && (scroll + max_choice > choice) &&
254 choice = choice - scroll;
258 if ((choice >= max_choice)) {
259 if (choice >= item_count() - max_choice / 2)
262 scroll = first_item = choice - max_choice / 2;
263 choice = choice - scroll;
268 print_item(first_item + i, i, i == choice);
277 wmove(menu, choice, item_x + 1);
289 for (i = choice + 1; i < max_choice; i++) {
309 print_item(scroll + choice, choice, FALSE);
312 if (choice < 2 && scroll) {
318 choice = MAX(choice - 1, 0);
321 print_item(scroll+choice, choice, FALSE);
323 if ((choice > max_choice - 3) &&
331 choice = MIN(choice + 1, max_choice - 1);
340 if (choice > 0)
341 choice--;
352 if (choice + 1 < max_choice)
353 choice++;
357 choice = i;
359 print_item(scroll + choice, choice, TRUE);
390 item_set(scroll + choice);
414 item_set(scroll + choice);