summaryrefslogtreecommitdiff
path: root/src/gui/windows/tradewindow.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2014-09-17 11:59:03 +0300
committerAndrei Karas <akaras@inbox.ru>2014-09-17 11:59:03 +0300
commit3aaebb5b7f1faf46d9f437ba00e7650147453952 (patch)
treefa5f0949dd16db6b30b0132a02f33d3fe784acb0 /src/gui/windows/tradewindow.cpp
parentc81a850333f6e651e0dddb764e98a0fae45ca5f4 (diff)
downloadmv-3aaebb5b7f1faf46d9f437ba00e7650147453952.tar.gz
mv-3aaebb5b7f1faf46d9f437ba00e7650147453952.tar.bz2
mv-3aaebb5b7f1faf46d9f437ba00e7650147453952.tar.xz
mv-3aaebb5b7f1faf46d9f437ba00e7650147453952.zip
Remove getter for tradeHandler.
Diffstat (limited to 'src/gui/windows/tradewindow.cpp')
-rw-r--r--src/gui/windows/tradewindow.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/gui/windows/tradewindow.cpp b/src/gui/windows/tradewindow.cpp
index 7707bf360..7f6e78a9b 100644
--- a/src/gui/windows/tradewindow.cpp
+++ b/src/gui/windows/tradewindow.cpp
@@ -273,7 +273,7 @@ void TradeWindow::tradeItem(const Item *const item, const int quantity,
if (check && !checkItem(item))
return;
- Net::getTradeHandler()->addItem(item, quantity);
+ tradeHandler->addItem(item, quantity);
}
void TradeWindow::valueChanged(const SelectionEvent &event)
@@ -365,7 +365,7 @@ void TradeWindow::action(const ActionEvent &event)
setVisible(false);
reset();
PlayerInfo::setTrading(false);
- Net::getTradeHandler()->cancel();
+ tradeHandler->cancel();
}
else if (eventId == "ok")
{
@@ -374,13 +374,13 @@ void TradeWindow::action(const ActionEvent &event)
mMoneyChangeButton->setEnabled(false);
receivedOk(true);
setStatus(PROPOSING);
- Net::getTradeHandler()->confirm();
+ tradeHandler->confirm();
}
else if (eventId == "trade")
{
receivedOk(true);
setStatus(ACCEPTED);
- Net::getTradeHandler()->finish();
+ tradeHandler->finish();
}
else if (eventId == "money")
{
@@ -399,14 +399,14 @@ void TradeWindow::action(const ActionEvent &event)
}
v = curMoney;
}
- Net::getTradeHandler()->setMoney(v);
+ tradeHandler->setMoney(v);
mMoneyField->setText(strprintf("%d", v));
}
}
void TradeWindow::close()
{
- Net::getTradeHandler()->cancel();
+ tradeHandler->cancel();
clear();
}
@@ -457,7 +457,7 @@ void TradeWindow::initTrade(const std::string &nick)
}
if (mAutoMoney)
{
- Net::getTradeHandler()->setMoney(mAutoMoney);
+ tradeHandler->setMoney(mAutoMoney);
mMoneyField->setText(strprintf("%d", mAutoMoney));
}
}