diff options
Diffstat (limited to 'src/gui/trade.cpp')
-rw-r--r-- | src/gui/trade.cpp | 17 |
1 files changed, 9 insertions, 8 deletions
diff --git a/src/gui/trade.cpp b/src/gui/trade.cpp index c57cac59..2f6007a9 100644 --- a/src/gui/trade.cpp +++ b/src/gui/trade.cpp @@ -1,9 +1,8 @@ /* - * Aethyra + * The Mana World * Copyright (C) 2004 The Mana World Development Team * - * This file is part of Aethyra based on original code - * from The Mana World. + * This file is part of The Mana World. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -38,13 +37,14 @@ #include "../inventory.h" #include "../item.h" #include "../localplayer.h" +#include "../units.h" #include "../net/messageout.h" #include "../net/protocol.h" #include "../utils/gettext.h" #include "../utils/strprintf.h" -#include "../utils/tostring.h" +#include "../utils/stringutils.h" TradeWindow::TradeWindow(Network *network): Window(_("Trade: You")), @@ -52,7 +52,7 @@ TradeWindow::TradeWindow(Network *network): mMyInventory(new Inventory(INVENTORY_SIZE)), mPartnerInventory(new Inventory(INVENTORY_SIZE)) { - setWindowName(_("Trade")); + setWindowName("Trade"); setDefaultSize(115, 227, 342, 209); setResizable(true); @@ -78,7 +78,7 @@ TradeWindow::TradeWindow(Network *network): mPartnerScroll = new ScrollArea(mPartnerItemContainer); - mMoneyLabel = new gcn::Label(strprintf(_("You get %d GP."), 0)); + mMoneyLabel = new gcn::Label(strprintf(_("You get %s."), "")); mMoneyLabel2 = new gcn::Label(_("You give:")); mMoneyField = new TextField; mMoneyField->setWidth(50); @@ -120,7 +120,8 @@ void TradeWindow::widgetResized(const gcn::Event &event) void TradeWindow::addMoney(int amount) { - mMoneyLabel->setCaption(strprintf(_("You get %d GP."), amount)); + mMoneyLabel->setCaption(strprintf(_("You get %s."), + Units::formatCurrency(amount).c_str())); mMoneyLabel->adjustSize(); } @@ -170,7 +171,7 @@ void TradeWindow::reset() mOkButton->setEnabled(true); mOkOther = false; mOkMe = false; - mMoneyLabel->setCaption(strprintf(_("You get %d GP."), 0)); + mMoneyLabel->setCaption(strprintf(_("You get %s."), "")); mMoneyField->setEnabled(true); mMoneyField->setText(""); } |