summaryrefslogtreecommitdiff
path: root/src/menu.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/menu.h')
-rw-r--r--src/menu.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/menu.h b/src/menu.h
index 862205e8..b5b78c74 100644
--- a/src/menu.h
+++ b/src/menu.h
@@ -234,6 +234,8 @@ template <class T> void Menu<T>::DeleteOption(size_t pos)
return;
delete itsOptions.at(pos).Item;
itsOptions.erase(itsOptions.begin()+pos);
+ if (itsOptions.empty())
+ Window::Clear();
}
template <class T> void Menu<T>::IntoSeparator(size_t pos)
@@ -262,7 +264,7 @@ template <class T> void Menu<T>::Refresh()
{
if (itsOptions.empty())
{
- Window::Clear();
+ Window::Refresh();
return;
}
int MaxBeginning = itsOptions.size() < itsHeight ? 0 : itsOptions.size()-itsHeight;