diff options
author | Andrei Karas <akaras@inbox.ru> | 2012-09-23 15:11:03 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2012-09-23 15:11:03 +0300 |
commit | bc4c9a33066e26bcdd3c564c90294777a839a5be (patch) | |
tree | 2ae1d07a962733394ac24eb5329407b6d81477ff /src | |
parent | 88df3eb6e82e1a23f379416652ac4f12f22a063c (diff) | |
download | plus-bc4c9a33066e26bcdd3c564c90294777a839a5be.tar.gz plus-bc4c9a33066e26bcdd3c564c90294777a839a5be.tar.bz2 plus-bc4c9a33066e26bcdd3c564c90294777a839a5be.tar.xz plus-bc4c9a33066e26bcdd3c564c90294777a839a5be.zip |
Fix unused empty space in onscreen buttons.
Diffstat (limited to 'src')
-rw-r--r-- | src/gui/windowmenu.cpp | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/src/gui/windowmenu.cpp b/src/gui/windowmenu.cpp index f33fe3e87..e0bd1c843 100644 --- a/src/gui/windowmenu.cpp +++ b/src/gui/windowmenu.cpp @@ -239,10 +239,15 @@ void WindowMenu::addButton(const char *const text, add(btn); btn->setFocusable(false); if (!visible) + { btn->setVisible(false); + } + else + { + x += btn->getWidth() + 3; + h = btn->getHeight(); + } mButtons.push_back(btn); - x += btn->getWidth() + 3; - h = btn->getHeight(); mButtonNames[text] = btn; } |