diff options
author | Andrei Karas <akaras@inbox.ru> | 2011-11-13 04:57:16 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2011-11-13 04:57:16 +0300 |
commit | 4d453108f45f9fb2ff4f5715cc1b3ddd63d36a80 (patch) | |
tree | c1edb8d8b368fdd43cd8639e6044b0f4e8dde70a /src/gui/statuswindow.cpp | |
parent | ece00592ecd93f7a96db0ca82589d00846e2f938 (diff) | |
parent | d471e99fd38ac589a8a9e8e8677b9f577f0cc5c6 (diff) | |
download | manaverse-4d453108f45f9fb2ff4f5715cc1b3ddd63d36a80.tar.gz manaverse-4d453108f45f9fb2ff4f5715cc1b3ddd63d36a80.tar.bz2 manaverse-4d453108f45f9fb2ff4f5715cc1b3ddd63d36a80.tar.xz manaverse-4d453108f45f9fb2ff4f5715cc1b3ddd63d36a80.zip |
Merge branch 'master' into strippedstripped1.1.11.12
Conflicts:
data/fonts/mplus-1p-bold.ttf
data/fonts/mplus-1p-regular.ttf
src/guichan/basiccontainer.cpp
src/guichan/focushandler.cpp
src/guichan/graphics.cpp
src/guichan/gui.cpp
src/guichan/image.cpp
src/guichan/include/guichan/widgets/checkbox.hpp
src/guichan/include/guichan/widgets/dropdown.hpp
src/guichan/sdl/sdlgraphics.cpp
src/guichan/sdl/sdlimage.cpp
src/guichan/widget.cpp
src/guichan/widgets/dropdown.cpp
src/guichan/widgets/icon.cpp
src/guichan/widgets/imagebutton.cpp
src/guichan/widgets/listbox.cpp
src/guichan/widgets/scrollarea.cpp
src/guichan/widgets/tab.cpp
src/guichan/widgets/tabbedarea.cpp
src/guichan/widgets/textbox.cpp
src/guichan/widgets/window.cpp
Diffstat (limited to 'src/gui/statuswindow.cpp')
-rw-r--r-- | src/gui/statuswindow.cpp | 37 |
1 files changed, 29 insertions, 8 deletions
diff --git a/src/gui/statuswindow.cpp b/src/gui/statuswindow.cpp index c746eb82d..37a706baf 100644 --- a/src/gui/statuswindow.cpp +++ b/src/gui/statuswindow.cpp @@ -123,7 +123,8 @@ class ChangeDisplay : public AttrDisplay, gcn::ActionListener }; StatusWindow::StatusWindow(): - Window(player_node ? player_node->getName() : "?", false, 0, "status.xml") + Window(player_node ? player_node->getName() : + "?", false, nullptr, "status.xml") { listen(Mana::CHANNEL_ATTRIBUTES); @@ -177,8 +178,8 @@ StatusWindow::StatusWindow(): } else { - mMpLabel = 0; - mMpBar = 0; + mMpLabel = nullptr; + mMpBar = nullptr; } place(0, 0, mLvlLabel, 3); @@ -210,9 +211,9 @@ StatusWindow::StatusWindow(): } else { - mJobLvlLabel = 0; - mJobLabel = 0; - mJobBar = 0; + mJobLvlLabel = nullptr; + mJobLabel = nullptr; + mJobBar = nullptr; } // ---------------------- @@ -787,6 +788,25 @@ void StatusWindow::updateStatusBar(ProgressBar *bar, bool percent A_UNUSED) break; } + switch (player_node->getPvpAttackType()) + { + case 0: + str += translateLetter(N_("(a)")); + break; + case 1: + str += translateLetter(N_("(f)")); + break; + case 2: + str += translateLetter(N_("(b)")); + break; + case 3: + str += translateLetter(N_("(d)")); + break; + default: + str += translateLetter(N_("(?)")); + break; + } + str += " " + toString(player_node->getQuickDropCounter()); switch (player_node->getPickUpType()) @@ -873,7 +893,7 @@ void StatusWindow::updateStatusBar(ProgressBar *bar, bool percent A_UNUSED) break; } - switch ((int)player_node->getAwayMode()) + switch ((int)player_node->getAway()) { case 0: str += translateLetter(N_("(O)")); @@ -944,6 +964,7 @@ AttrDisplay::AttrDisplay(int id, const std::string &name): AttrDisplay::~AttrDisplay() { delete mLayout; + mLayout = nullptr; } std::string AttrDisplay::update() @@ -993,7 +1014,7 @@ ChangeDisplay::ChangeDisplay(int id, const std::string &name): } else { - mDec = 0; + mDec = nullptr; } update(); |