Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 38151
b: refs/heads/master
c: 737ecae
h: refs/heads/master
i:
  38149: 8e3c8f8
  38147: c646e93
  38143: 9a2a82d
v: v3
  • Loading branch information
Sam Ravnborg committed Sep 30, 2006
1 parent e773f93 commit 32d2cc8
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: c29121b787f533d135ae47b5f3044adb66cbebef
refs/heads/master: 737ecae264bc759e2033d99e99138f690f3beabf
12 changes: 6 additions & 6 deletions trunk/scripts/kconfig/lxdialog/menubox.c
Original file line number Diff line number Diff line change
Expand Up @@ -63,19 +63,19 @@ static int menu_width, item_x;
/*
* Print menu item
*/
static void do_print_item(WINDOW * win, const char *item, int choice,
static void do_print_item(WINDOW * win, const char *item, int line_y,
int selected, int hotkey)
{
int j;
char *menu_item = malloc(menu_width + 1);

strncpy(menu_item, item, menu_width - item_x);
menu_item[menu_width] = 0;
menu_item[menu_width - item_x] = '\0';
j = first_alpha(menu_item, "YyNnMmHh");

/* Clear 'residue' of last item */
wattrset(win, dlg.menubox.atr);
wmove(win, choice, 0);
wmove(win, line_y, 0);
#if OLD_NCURSES
{
int i;
Expand All @@ -86,14 +86,14 @@ static void do_print_item(WINDOW * win, const char *item, int choice,
wclrtoeol(win);
#endif
wattrset(win, selected ? dlg.item_selected.atr : dlg.item.atr);
mvwaddstr(win, choice, item_x, menu_item);
mvwaddstr(win, line_y, item_x, menu_item);
if (hotkey) {
wattrset(win, selected ? dlg.tag_key_selected.atr
: dlg.tag_key.atr);
mvwaddch(win, choice, item_x + j, menu_item[j]);
mvwaddch(win, line_y, item_x + j, menu_item[j]);
}
if (selected) {
wmove(win, choice, item_x + 1);
wmove(win, line_y, item_x + 1);
}
free(menu_item);
wrefresh(win);
Expand Down

0 comments on commit 32d2cc8

Please sign in to comment.