summaryrefslogtreecommitdiff
path: root/src/client.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2012-01-30 01:11:09 +0300
committerAndrei Karas <akaras@inbox.ru>2012-01-30 19:53:08 +0300
commite754d2d1f4f45238974d2136baf5eff0058784a4 (patch)
tree0fec5502261a0c5100be2156e7636392a7dc2b7d /src/client.cpp
parente94e85962956eacfcfe67269220cb4cbff7978fd (diff)
downloadplus-e754d2d1f4f45238974d2136baf5eff0058784a4.tar.gz
plus-e754d2d1f4f45238974d2136baf5eff0058784a4.tar.bz2
plus-e754d2d1f4f45238974d2136baf5eff0058784a4.tar.xz
plus-e754d2d1f4f45238974d2136baf5eff0058784a4.zip
Fix buttons position while resizing in server selection screen.
Diffstat (limited to 'src/client.cpp')
-rw-r--r--src/client.cpp21
1 files changed, 19 insertions, 2 deletions
diff --git a/src/client.cpp b/src/client.cpp
index 0a47b2bee..0e62d9a52 100644
--- a/src/client.cpp
+++ b/src/client.cpp
@@ -2368,13 +2368,30 @@ void Client::resizeVideo(int width, int height)
if (mainGraphics->resize(width, height))
{
- gui->videoResized();
+ if (gui)
+ gui->videoResized();
if (mDesktop)
mDesktop->setSize(width, height);
if (mSetupButton)
- mSetupButton->setPosition(width - mSetupButton->getWidth() - 3, 3);
+ {
+// mSetupButton->setPosition(width - mSetupButton->getWidth() - 3, 3);
+
+ int x = width - mSetupButton->getWidth() - 3;
+ mSetupButton->setPosition(x, 3);
+
+#ifndef WIN32
+ x -= mPerfomanceButton->getWidth() + 6;
+ mPerfomanceButton->setPosition(x, 3);
+
+ x -= mVideoButton->getWidth() + 6;
+ mVideoButton->setPosition(x, 3);
+
+ x -= mThemesButton->getWidth() + 6;
+ mThemesButton->setPosition(x, 3);
+#endif
+ }
if (mGame)
mGame->videoResized(width, height);