From d9b7eaef2b17b09c8f5c9f587f66adcbde399fc4 Mon Sep 17 00:00:00 2001 From: Maxime Coste Date: Mon, 30 Dec 2013 22:41:08 +0000 Subject: [PATCH] NCursesUI: no item is selected on menu_show --- src/ncurses.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/ncurses.cc b/src/ncurses.cc index 207da1e2..b80558fb 100644 --- a/src/ncurses.cc +++ b/src/ncurses.cc @@ -478,7 +478,7 @@ void NCursesUI::menu_show(memoryview items, int line = (int)anchor.line + 1; if (line + height >= (int)maxsize.line) line = (int)anchor.line - height; - m_selected_item = 0; + m_selected_item = item_count; m_menu_top_line = 0; int width = is_prompt ? (int)maxsize.column : (int)longest;