Skip to content

Commit

Permalink
kconfig: enhancing accessibility of lxdialog
Browse files Browse the repository at this point in the history
Some fix that I forgot for good accessibility of lxdialog (the cursor
should always be left at the focus location):

Have the checklist display the currently highlighted entry last, for having
the cursor left on it (rather than on the last line of the list).

Signed-off-by: Samuel Thibault <samuel.thibault@ens-lyon.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
  • Loading branch information
Samuel Thibault authored and Sam Ravnborg committed Jul 1, 2006
1 parent 5e8d780 commit 66392c4
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions scripts/kconfig/lxdialog/checklist.c
Original file line number Diff line number Diff line change
Expand Up @@ -187,9 +187,12 @@ int dialog_checklist(const char *title, const char *prompt, int height,

/* Print the list */
for (i = 0; i < max_choice; i++) {
print_item(list, items[(scroll + i) * 3 + 1],
status[i + scroll], i, i == choice);
if (i != choice)
print_item(list, items[(scroll + i) * 3 + 1],
status[i + scroll], i, 0);
}
print_item(list, items[(scroll + choice) * 3 + 1],
status[choice + scroll], choice, 1);

print_arrows(dialog, choice, item_no, scroll,
box_y, box_x + check_x + 5, list_height);
Expand Down

0 comments on commit 66392c4

Please sign in to comment.