summaryrefslogtreecommitdiff
path: root/src/gui/windows/charselectdialog.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2014-10-06 00:12:33 +0300
committerAndrei Karas <akaras@inbox.ru>2014-10-06 00:12:33 +0300
commit87faf131575091160e9776c511e24b65e8b6b2e9 (patch)
tree99f057c18ff79f1e8064be146c65fca4f50e2616 /src/gui/windows/charselectdialog.cpp
parent7901ff853659fb9dda0218eac22c740dd44b1bd3 (diff)
downloadplus-87faf131575091160e9776c511e24b65e8b6b2e9.tar.gz
plus-87faf131575091160e9776c511e24b65e8b6b2e9.tar.bz2
plus-87faf131575091160e9776c511e24b65e8b6b2e9.tar.xz
plus-87faf131575091160e9776c511e24b65e8b6b2e9.zip
Disable char rename button if for selected char not allowed rename.
Diffstat (limited to 'src/gui/windows/charselectdialog.cpp')
-rw-r--r--src/gui/windows/charselectdialog.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/gui/windows/charselectdialog.cpp b/src/gui/windows/charselectdialog.cpp
index 32a3ea410..8d80fe1f7 100644
--- a/src/gui/windows/charselectdialog.cpp
+++ b/src/gui/windows/charselectdialog.cpp
@@ -593,6 +593,11 @@ void CharSelectDialog::updateState()
{
// TRANSLATORS: char select dialog. button.
mPlayButton->setCaption(_("Play"));
+
+ LocalPlayer *const player = mCharacterEntries[
+ idx]->getCharacter()->dummy;
+ if (player)
+ mRenameButton->setEnabled(player->getRename() ? true : false);
}
else
{