diff options
author | Andrei Karas <akaras@inbox.ru> | 2014-09-17 10:31:03 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2014-09-17 10:31:03 +0300 |
commit | 9cdbed6c562f95e24e02f49630386f8b18884a02 (patch) | |
tree | 4dad8316607387c80b66cf42b2a806ffa1a3afed /src/gui/windows | |
parent | 3a7313c027407e3b35360a021c72fe78f181d81d (diff) | |
download | plus-9cdbed6c562f95e24e02f49630386f8b18884a02.tar.gz plus-9cdbed6c562f95e24e02f49630386f8b18884a02.tar.bz2 plus-9cdbed6c562f95e24e02f49630386f8b18884a02.tar.xz plus-9cdbed6c562f95e24e02f49630386f8b18884a02.zip |
Remove getter for gameHandler.
Diffstat (limited to 'src/gui/windows')
-rw-r--r-- | src/gui/windows/ministatuswindow.cpp | 4 | ||||
-rw-r--r-- | src/gui/windows/quitdialog.cpp | 2 | ||||
-rw-r--r-- | src/gui/windows/statuswindow.cpp | 2 |
3 files changed, 4 insertions, 4 deletions
diff --git a/src/gui/windows/ministatuswindow.cpp b/src/gui/windows/ministatuswindow.cpp index 618e8fb74..ba4aaf8c7 100644 --- a/src/gui/windows/ministatuswindow.cpp +++ b/src/gui/windows/ministatuswindow.cpp @@ -70,7 +70,7 @@ MiniStatusWindow::MiniStatusWindow() : mHpBar(createBar(0, 100, 0, Theme::HP_BAR, Theme::PROG_HP, "hpprogressbar.xml", "hpprogressbar_fill.xml", "hp bar", _("health bar"))), - mMpBar(Net::getGameHandler()->canUseMagicBar() + mMpBar(gameHandler->canUseMagicBar() ? createBar(0, 100, 0, Net::getPlayerHandler()->canUseMagic() ? Theme::MP_BAR : Theme::NO_MP_BAR, Net::getPlayerHandler()->canUseMagic() @@ -119,7 +119,7 @@ MiniStatusWindow::MiniStatusWindow() : StatusWindow::updateHPBar(mHpBar); - if (Net::getGameHandler()->canUseMagicBar() && statusWindow) + if (gameHandler->canUseMagicBar() && statusWindow) statusWindow->updateMPBar(mMpBar); const int job = Net::getPlayerHandler()->getJobLocation() diff --git a/src/gui/windows/quitdialog.cpp b/src/gui/windows/quitdialog.cpp index 2f9cf51c5..f5481070a 100644 --- a/src/gui/windows/quitdialog.cpp +++ b/src/gui/windows/quitdialog.cpp @@ -183,7 +183,7 @@ void QuitDialog::action(const ActionEvent &event) client->setState(STATE_EXIT); } } - else if (Net::getGameHandler()->isConnected() + else if (gameHandler->isConnected() && mSwitchAccountServer->isSelected()) { DialogsManager::closeDialogs(); diff --git a/src/gui/windows/statuswindow.cpp b/src/gui/windows/statuswindow.cpp index a49545df3..08480cdd4 100644 --- a/src/gui/windows/statuswindow.cpp +++ b/src/gui/windows/statuswindow.cpp @@ -128,7 +128,7 @@ StatusWindow::StatusWindow() : mXpBar->setColor(getThemeColor(Theme::XP_BAR), getThemeColor(Theme::XP_BAR_OUTLINE)); - const bool magicBar = Net::getGameHandler()->canUseMagicBar(); + const bool magicBar = gameHandler->canUseMagicBar(); const int job = Net::getPlayerHandler()->getJobLocation() && serverConfig.getValueBool("showJob", true); |