Fix NCursesUI::m_items not being empty after a resize

Fixes #435
This commit is contained in:
Maxime Coste 2015-10-13 13:40:04 +01:00
parent 2d7e99da98
commit e5240ba4ff

View File

@ -630,6 +630,7 @@ void NCursesUI::menu_show(ConstArrayView<DisplayLine> items,
return;
const int item_count = items.size();
m_items.clear(); // make sure it is empty
m_items.reserve(item_count);
CharCount longest = 0;
const CharCount maxlen = min((int)maxsize.column-2, 200);