summaryrefslogtreecommitdiffstats
path: root/ui/ncurses/nc-menu.c
diff options
context:
space:
mode:
authorGeoff Levand <geoffrey.levand@am.sony.com>2009-07-09 10:40:44 -0700
committerGeoff Levand <geoffrey.levand@am.sony.com>2009-07-09 10:40:44 -0700
commit25cb540c8b73a044911ef7dab5b57879de1779e9 (patch)
tree98ba5afa33d41c7c063d8d50d706d55cdd1c57ea /ui/ncurses/nc-menu.c
parentea0a5877530a801713c80963c918c0a6f4072d8a (diff)
downloadtalos-petitboot-25cb540c8b73a044911ef7dab5b57879de1779e9.tar.gz
talos-petitboot-25cb540c8b73a044911ef7dab5b57879de1779e9.zip
CUI add empty item
Add a CUI hot-key 'o' that opens a new empty menu item. Signed-off-by: Geoff Levand <geoffrey.levand@am.sony.com>
Diffstat (limited to 'ui/ncurses/nc-menu.c')
-rw-r--r--ui/ncurses/nc-menu.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/ui/ncurses/nc-menu.c b/ui/ncurses/nc-menu.c
index 0a76b11..1dc34a1 100644
--- a/ui/ncurses/nc-menu.c
+++ b/ui/ncurses/nc-menu.c
@@ -174,13 +174,16 @@ static void pmenu_process_key(struct nc_scr *scr)
case '\t':
pmenu_move_cursor(menu, REQ_DOWN_ITEM);
break;
-
case KEY_LEFT:
- case 'E':
case 'e':
if (item->on_edit)
item->on_edit(item);
break;
+ case 'o':
+ DBGS("on_open: %p\n", menu->on_open);
+ if (menu->on_open)
+ menu->on_open(menu);
+ break;
case '\n':
case '\r':
if (item->on_execute)
OpenPOWER on IntegriCloud