summaryrefslogtreecommitdiff
path: root/src/gui/windowmenu.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui/windowmenu.cpp')
-rw-r--r--src/gui/windowmenu.cpp11
1 files changed, 7 insertions, 4 deletions
diff --git a/src/gui/windowmenu.cpp b/src/gui/windowmenu.cpp
index c57cd8974..6133c69e0 100644
--- a/src/gui/windowmenu.cpp
+++ b/src/gui/windowmenu.cpp
@@ -60,7 +60,7 @@ extern Window *socialWindow;
WindowMenu::WindowMenu():
mEmotePopup(nullptr),
mHaveMouse(false),
- mAutoHide(true)
+ mAutoHide(1)
{
int x = 0, h = 0;
@@ -114,7 +114,7 @@ WindowMenu::WindowMenu():
setVisible(true);
config.addListener("autohideButtons", this);
- mAutoHide = config.getBoolValue("autohideButtons");
+ mAutoHide = config.getIntValue("autohideButtons");
}
WindowMenu::~WindowMenu()
@@ -401,12 +401,15 @@ void WindowMenu::saveButtons()
void WindowMenu::drawChildren(gcn::Graphics* graphics)
{
- if (!mAutoHide || mHaveMouse)
+ if (mHaveMouse || !mAutoHide || (mAutoHide == 1
+ && mainGraphics && mainGraphics->mWidth > 800))
+ {
Container::drawChildren(graphics);
+ }
}
void WindowMenu::optionChanged(const std::string &name)
{
if (name == "autohideButtons")
- mAutoHide = config.getBoolValue("autohideButtons");
+ mAutoHide = config.getIntValue("autohideButtons");
}