diff options
author | Andrei Karas <akaras@inbox.ru> | 2014-10-10 15:31:36 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2014-10-10 15:31:36 +0300 |
commit | c757bf80478dd5e4e40a6c24b436954ab498a855 (patch) | |
tree | 8b73b31f6ca857d3a7affb86e324990b70baf68a /src/gui/windows/charselectdialog.cpp | |
parent | a7524c70c71cbdaed7e541105d9c743fb18f56cf (diff) | |
download | manaverse-c757bf80478dd5e4e40a6c24b436954ab498a855.tar.gz manaverse-c757bf80478dd5e4e40a6c24b436954ab498a855.tar.bz2 manaverse-c757bf80478dd5e4e40a6c24b436954ab498a855.tar.xz manaverse-c757bf80478dd5e4e40a6c24b436954ab498a855.zip |
Fix code style.
Diffstat (limited to 'src/gui/windows/charselectdialog.cpp')
-rw-r--r-- | src/gui/windows/charselectdialog.cpp | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/src/gui/windows/charselectdialog.cpp b/src/gui/windows/charselectdialog.cpp index 5ec3ab2b7..fef43b605 100644 --- a/src/gui/windows/charselectdialog.cpp +++ b/src/gui/windows/charselectdialog.cpp @@ -26,8 +26,6 @@ #include "configuration.h" #include "units.h" -#include "events/keyevent.h" - #include "input/inputaction.h" #include "being/attributes.h" @@ -234,7 +232,7 @@ void CharSelectDialog::action(const ActionEvent &event) else if (eventId == "rename" && mCharacterEntries[selected]->getCharacter()) { - LocalPlayer *const player = mCharacterEntries[ + const LocalPlayer *const player = mCharacterEntries[ selected]->getCharacter()->dummy; EditDialog *const dialog = new EditDialog( _("Please enter new name"), player->getName(), "OK"); @@ -525,8 +523,7 @@ void CharSelectDialog::setLocked(const bool locked) mUnregisterButton->setEnabled(!locked); if (mChangeEmailButton) mChangeEmailButton->setEnabled(!locked); - if (mPlayButton) - mPlayButton->setEnabled(!locked); + mPlayButton->setEnabled(!locked); if (mDeleteButton) mDeleteButton->setEnabled(!locked); @@ -575,8 +572,7 @@ void CharSelectDialog::close() void CharSelectDialog::widgetResized(const Event &event) { Window::widgetResized(event); - if (mCharacterView) - mCharacterView->resize(); + mCharacterView->resize(); } void CharSelectDialog::updateState() @@ -594,7 +590,7 @@ void CharSelectDialog::updateState() // TRANSLATORS: char select dialog. button. mPlayButton->setCaption(_("Play")); - LocalPlayer *const player = mCharacterEntries[ + const LocalPlayer *const player = mCharacterEntries[ idx]->getCharacter()->dummy; if (player && mRenameButton) mRenameButton->setEnabled(player->getRename() ? true : false); |