Lines Matching defs:choice
81 #define print_item(index, choice, selected) \
84 do_print_item(menu, item_str(), choice, selected, !item_is_tag(':')); \
168 int key = 0, button = 0, scroll = 0, choice = 0;
226 /* Set choice to default item */
229 choice = item_n();
232 if ((scroll <= choice) && (scroll + max_choice > choice) &&
235 choice = choice - scroll;
239 if ((choice >= max_choice)) {
240 if (choice >= item_count() - max_choice / 2)
243 scroll = first_item = choice - max_choice / 2;
244 choice = choice - scroll;
249 print_item(first_item + i, i, i == choice);
258 wmove(menu, choice, item_x + 1);
270 for (i = choice + 1; i < max_choice; i++) {
291 print_item(scroll + choice, choice, FALSE);
294 if (choice < 2 && scroll) {
300 choice = MAX(choice - 1, 0);
303 print_item(scroll+choice, choice, FALSE);
305 if ((choice > max_choice - 3) &&
313 choice = MIN(choice + 1, max_choice - 1);
322 if (choice > 0)
323 choice--;
334 if (choice + 1 < max_choice)
335 choice++;
339 choice = i;
341 print_item(scroll + choice, choice, TRUE);
376 item_set(scroll + choice);