summaryrefslogtreecommitdiff
path: root/src/gui/windows/botcheckerwindow.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2014-03-01 19:13:11 +0300
committerAndrei Karas <akaras@inbox.ru>2014-03-01 19:13:11 +0300
commita260aeab234704ace8ba672b1d1ce57e18425e07 (patch)
treee215c6eeeae7e6c2ca4f4453718cef6ca9a8af6a /src/gui/windows/botcheckerwindow.cpp
parent382067b05c4fe97bcf0da0143405375ec295f7c6 (diff)
parent2c62286a7ecf246e8a445dd7d00f618efae2a96a (diff)
downloadmv-a260aeab234704ace8ba672b1d1ce57e18425e07.tar.gz
mv-a260aeab234704ace8ba672b1d1ce57e18425e07.tar.bz2
mv-a260aeab234704ace8ba672b1d1ce57e18425e07.tar.xz
mv-a260aeab234704ace8ba672b1d1ce57e18425e07.zip
Merge branch 'master' into stable
Diffstat (limited to 'src/gui/windows/botcheckerwindow.cpp')
-rw-r--r--src/gui/windows/botcheckerwindow.cpp24
1 files changed, 12 insertions, 12 deletions
diff --git a/src/gui/windows/botcheckerwindow.cpp b/src/gui/windows/botcheckerwindow.cpp
index b94093ebb..d1fc0e7bd 100644
--- a/src/gui/windows/botcheckerwindow.cpp
+++ b/src/gui/windows/botcheckerwindow.cpp
@@ -101,7 +101,7 @@ public:
freeWidgets();
mPlayers.clear();
if (actorManager && botCheckerWindow
- && botCheckerWindow->mEnabled)
+ && botCheckerWindow->mBotcheckerEnabled)
{
std::set<ActorSprite*> beings = actorManager->getAll();
FOR_EACH (ActorSprites::iterator, i, beings)
@@ -125,7 +125,7 @@ public:
continue;
const Being *const player = mPlayers.at(r);
- gcn::Widget *widget = new Label(this, player->getName());
+ Widget *widget = new Label(this, player->getName());
mWidgets.push_back(widget);
@@ -235,14 +235,14 @@ public:
{
}
- gcn::Widget *getElementAt(const int row, const int column) const
+ Widget *getElementAt(const int row, const int column) const
{
return mWidgets[WIDGET_AT(row, column)];
}
void freeWidgets()
{
- for (std::vector<gcn::Widget *>::const_iterator it = mWidgets.begin();
+ for (std::vector<Widget *>::const_iterator it = mWidgets.begin();
it != mWidgets.end(); ++it)
{
delete *it;
@@ -253,17 +253,17 @@ public:
protected:
std::vector<Being*> mPlayers;
- std::vector<gcn::Widget*> mWidgets;
+ std::vector<Widget*> mWidgets;
};
BotCheckerWindow::BotCheckerWindow():
// TRANSLATORS: bot checker window header
Window(_("Bot Checker"), false, nullptr, "botchecker.xml"),
- gcn::ActionListener(),
+ ActionListener(),
mTableModel(new UsersTableModel(this)),
mTable(new GuiTable(this, mTableModel)),
- playersScrollArea(new ScrollArea(mTable, true,
+ playersScrollArea(new ScrollArea(this, mTable, true,
"bochecker_background.xml")),
mPlayerTableTitleModel(new StaticTableModel(1, COLUMNS_NR)),
mPlayerTitleTable(new GuiTable(this, mPlayerTableTitleModel)),
@@ -271,7 +271,7 @@ BotCheckerWindow::BotCheckerWindow():
mIncButton(new Button(this, _("Reset"), "reset", this)),
mLastUpdateTime(0),
mNeedUpdate(false),
- mEnabled(false)
+ mBotcheckerEnabled(false)
{
const int w = 500;
const int h = 250;
@@ -346,7 +346,7 @@ BotCheckerWindow::BotCheckerWindow():
enableVisibleSound(true);
config.addListener("enableBotCheker", this);
- mEnabled = config.getBoolValue("enableBotCheker");
+ mBotcheckerEnabled = config.getBoolValue("enableBotCheker");
}
BotCheckerWindow::~BotCheckerWindow()
@@ -358,7 +358,7 @@ BotCheckerWindow::~BotCheckerWindow()
void BotCheckerWindow::slowLogic()
{
BLOCK_START("BotCheckerWindow::slowLogic")
- if (mEnabled && mTableModel)
+ if (mBotcheckerEnabled && mTableModel)
{
const unsigned int nowTime = cur_time;
if (nowTime - mLastUpdateTime > 5 && mNeedUpdate)
@@ -377,7 +377,7 @@ void BotCheckerWindow::slowLogic()
BLOCK_END("BotCheckerWindow::slowLogic")
}
-void BotCheckerWindow::action(const gcn::ActionEvent &event)
+void BotCheckerWindow::action(const ActionEvent &event)
{
if (event.getId() == "reset")
{
@@ -417,7 +417,7 @@ void BotCheckerWindow::reset()
void BotCheckerWindow::optionChanged(const std::string &name)
{
if (name == "enableBotCheker")
- mEnabled = config.getBoolValue("enableBotCheker");
+ mBotcheckerEnabled = config.getBoolValue("enableBotCheker");
}
#ifdef USE_PROFILER