summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBjørn Lindeijer <bjorn@lindeijer.nl>2007-03-20 23:39:18 +0000
committerBjørn Lindeijer <bjorn@lindeijer.nl>2007-03-20 23:39:18 +0000
commitabd8cda8455dbd13c7335d6bca2620b651e1b54f (patch)
tree9a6c7e87ce7e201d1642e6061a3a292eef8b701e
parent2dd7568047c7b0af8a7c8a656f1bb6708fb856c6 (diff)
downloadmana-abd8cda8455dbd13c7335d6bca2620b651e1b54f.tar.gz
mana-abd8cda8455dbd13c7335d6bca2620b651e1b54f.tar.bz2
mana-abd8cda8455dbd13c7335d6bca2620b651e1b54f.tar.xz
mana-abd8cda8455dbd13c7335d6bca2620b651e1b54f.zip
Fixed small issue where default server didn't fit in the server entry field
properly.
-rw-r--r--ChangeLog2
-rw-r--r--src/gui/login.cpp22
2 files changed, 15 insertions, 9 deletions
diff --git a/ChangeLog b/ChangeLog
index 771440f1..38f15618 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -4,6 +4,8 @@
src/resources/image.cpp: Reduced amount of useless logging, calculate
nearest power of two in a function and only do the alpha check in
software mode.
+ * src/gui/login.cpp: Fixed small issue where default server didn't fit
+ in the server entry field properly.
2007-03-20 David Athay <ko2fan@gmail.com>
diff --git a/src/gui/login.cpp b/src/gui/login.cpp
index cda57103..27623442 100644
--- a/src/gui/login.cpp
+++ b/src/gui/login.cpp
@@ -68,7 +68,10 @@ LoginDialog::LoginDialog(LoginData *loginData):
mCancelButton = new Button("Cancel", "cancel", this);
mRegisterButton = new Button("Register", "register", this);
- setContentSize(200, 100);
+ const int width = 220;
+ const int height = 100;
+
+ setContentSize(width, height);
userLabel->setPosition(5, 5);
passLabel->setPosition(5, 14 + userLabel->getHeight());
@@ -78,18 +81,19 @@ LoginDialog::LoginDialog(LoginData *loginData):
mPassField->setPosition(65, 14 + userLabel->getHeight());
mServerField->setPosition(
65, 23 + userLabel->getHeight() + passLabel->getHeight());
- mUserField->setWidth(130);
- mPassField->setWidth(130);
- mServerField->setWidth(130);
+ mUserField->setWidth(width - 70);
+ mPassField->setWidth(width - 70);
+ mServerField->setWidth(width - 70);
mKeepCheck->setPosition(4, 77);
mCancelButton->setPosition(
- 200 - mCancelButton->getWidth() - 5,
- 100 - mCancelButton->getHeight() - 5);
+ width - mCancelButton->getWidth() - 5,
+ height - mCancelButton->getHeight() - 5);
mOkButton->setPosition(
mCancelButton->getX() - mOkButton->getWidth() - 5,
- 100 - mOkButton->getHeight() - 5);
- mRegisterButton->setPosition(mKeepCheck->getX() + mKeepCheck->getWidth() + 10,
- 100 - mRegisterButton->getHeight() - 5);
+ height - mOkButton->getHeight() - 5);
+ mRegisterButton->setPosition(
+ mKeepCheck->getX() + mKeepCheck->getWidth() + 10,
+ height - mRegisterButton->getHeight() - 5);
mUserField->setActionEventId("ok");
mPassField->setActionEventId("ok");