diff options
Diffstat (limited to 'src/net/tmwa/generalhandler.cpp')
-rw-r--r-- | src/net/tmwa/generalhandler.cpp | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/src/net/tmwa/generalhandler.cpp b/src/net/tmwa/generalhandler.cpp index 293986bde..a666fa5f4 100644 --- a/src/net/tmwa/generalhandler.cpp +++ b/src/net/tmwa/generalhandler.cpp @@ -2,7 +2,7 @@ * The ManaPlus Client * Copyright (C) 2009 The Mana World Development Team * Copyright (C) 2009-2010 The Mana Developers - * Copyright (C) 2011 The ManaPlus Developers + * Copyright (C) 2011-2012 The ManaPlus Developers * * This file is part of The ManaPlus Client. * @@ -201,9 +201,9 @@ void GeneralHandler::reload() static_cast<LoginHandler*>(mLoginHandler.get())->clearWorlds(); static_cast<CharServerHandler*>( - mCharHandler.get())->setCharCreateDialog(0); + mCharHandler.get())->setCharCreateDialog(nullptr); static_cast<CharServerHandler*>( - mCharHandler.get())->setCharSelectDialog(0); + mCharHandler.get())->setCharSelectDialog(nullptr); static_cast<PartyHandler*>(mPartyHandler.get())->reload(); } @@ -259,6 +259,9 @@ void GeneralHandler::processEvent(Mana::Channels channel, if (!statusWindow) return; + // protection against double addition attributes. + statusWindow->clearAttributes(); + statusWindow->addAttribute(STR, _("Strength"), true, ""); statusWindow->addAttribute(AGI, _("Agility"), true, ""); statusWindow->addAttribute(VIT, _("Vitality"), true, ""); |