Lines Matching refs:choice
67 print_item (WINDOW * win, const char *item, int choice, int selected, int hotkey) in print_item() argument
78 wmove (win, choice, 0); in print_item()
89 mvwaddstr (win, choice, item_x, menu_item); in print_item()
92 mvwaddch(win, choice, item_x+j, menu_item[j]); in print_item()
95 wmove (win, choice, item_x+1); in print_item()
172 int key = 0, button = 0, scroll = 0, choice = 0, first_item = 0, max_choice; in dialog_menu() local
234 if (strcmp(current, items[i*2]) == 0) choice = i; in dialog_menu()
241 if ( (fscanf(f,"%d\n",&scroll) == 1) && (scroll <= choice) && in dialog_menu()
242 (scroll+max_choice > choice) && (scroll >= 0) && in dialog_menu()
245 choice = choice - scroll; in dialog_menu()
254 if ( (choice >= max_choice) || (f==NULL && choice >= max_choice/2) ) { in dialog_menu()
255 if (choice >= item_no-max_choice/2) in dialog_menu()
258 scroll = first_item = choice - max_choice/2; in dialog_menu()
259 choice = choice - scroll; in dialog_menu()
264 print_item (menu, items[(first_item + i) * 2 + 1], i, i == choice, in dialog_menu()
274 wmove (menu, choice, item_x+1); in dialog_menu()
285 for (i = choice+1; i < max_choice; i++) { in dialog_menu()
303 print_item (menu, items[(scroll+choice)*2+1], choice, FALSE, in dialog_menu()
304 (items[(scroll+choice)*2][0] != ':')); in dialog_menu()
307 if (choice < 2 && scroll) { in dialog_menu()
318 choice = MAX(choice - 1, 0); in dialog_menu()
322 print_item (menu, items[(scroll+choice)*2+1], choice, FALSE, in dialog_menu()
323 (items[(scroll+choice)*2][0] != ':')); in dialog_menu()
325 if ((choice > max_choice-3) && in dialog_menu()
339 choice = MIN(choice+1, max_choice-1); in dialog_menu()
350 if (choice > 0) in dialog_menu()
351 choice--; in dialog_menu()
367 if (choice+1 < max_choice) in dialog_menu()
368 choice++; in dialog_menu()
373 choice = i; in dialog_menu()
375 print_item (menu, items[(scroll+choice)*2+1], choice, TRUE, in dialog_menu()
376 (items[(scroll+choice)*2][0] != ':')); in dialog_menu()
408 fprintf(stderr, "%s\n", items[(scroll + choice) * 2]); in dialog_menu()
424 items[(scroll + choice) * 2], in dialog_menu()
425 items[(scroll + choice) * 2 + 1] + in dialog_menu()
426 first_alpha(items[(scroll + choice) * 2 + 1],"")); in dialog_menu()
428 fprintf(stderr, "%s\n", items[(scroll + choice) * 2]); in dialog_menu()