diff options
Diffstat (limited to 'src/gui/windows/buyselldialog.cpp')
-rw-r--r-- | src/gui/windows/buyselldialog.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/gui/windows/buyselldialog.cpp b/src/gui/windows/buyselldialog.cpp index 15d4165f3..bdd28b000 100644 --- a/src/gui/windows/buyselldialog.cpp +++ b/src/gui/windows/buyselldialog.cpp @@ -35,7 +35,7 @@ BuySellDialog::DialogList BuySellDialog::dialogInstances; -BuySellDialog::BuySellDialog(const int npcId) : +BuySellDialog::BuySellDialog(const BeingId npcId) : // TRANSLATORS: shop window name Window(_("Shop"), Modal_false, nullptr, "buysell.xml"), ActionListener(), @@ -50,7 +50,7 @@ BuySellDialog::BuySellDialog(const std::string &nick) : // TRANSLATORS: shop window name Window(_("Shop"), Modal_false, nullptr, "buysell.xml"), ActionListener(), - mNpcId(-1), + mNpcId(BeingId_negOne), mNick(nick), mBuyButton(nullptr) { @@ -128,14 +128,14 @@ void BuySellDialog::action(const ActionEvent &event) const std::string &eventId = event.getId(); if (eventId == "Buy") { - if (mNpcId != -1) + if (mNpcId != BeingId_negOne) npcHandler->buy(mNpcId); else buySellHandler->requestSellList(mNick); } else if (eventId == "Sell") { - if (mNpcId != -1) + if (mNpcId != BeingId_negOne) npcHandler->sell(mNpcId); else buySellHandler->requestBuyList(mNick); |