Skip to content

Commit ba3b759

Browse files
MattBystrinmasahir0y
authored andcommitted
kconfig: lxdialog: fix cursor render in checklist
When a checklist is opened, the cursor is rendered in a wrong position (after the last list element on the screen). You can observe it by opening any checklist in menuconfig. Added wmove() to set the cursor in the proper position, just like in menubox.c. Removed wnoutrefresh(dialog) because dialog window has already been updated in print_buttons(). Replaced wnoutrefresh(list) and doupdate() calls with one wrefresh(list) call. Signed-off-by: Matthew Bystrin <[email protected]> Signed-off-by: Masahiro Yamada <[email protected]>
1 parent d2d5cba commit ba3b759

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

scripts/kconfig/lxdialog/checklist.c

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -188,9 +188,8 @@ int dialog_checklist(const char *title, const char *prompt, int height,
188188

189189
print_buttons(dialog, height, width, 0);
190190

191-
wnoutrefresh(dialog);
192-
wnoutrefresh(list);
193-
doupdate();
191+
wmove(list, choice, check_x + 1);
192+
wrefresh(list);
194193

195194
while (key != KEY_ESC) {
196195
key = wgetch(dialog);

0 commit comments

Comments
 (0)