diff options
author | Bjørn Lindeijer <bjorn@lindeijer.nl> | 2009-02-09 23:47:02 +0100 |
---|---|---|
committer | Bjørn Lindeijer <bjorn@lindeijer.nl> | 2009-02-09 23:47:02 +0100 |
commit | fa2f3ac593a792c32095c2e885665ec91bb4019d (patch) | |
tree | f44aee845f0229dfcc6b2ad3c74613e0352f36c2 /src/gui/popupmenu.cpp | |
parent | 07f7d52f661a74e6d0c780ca53e724651e3dcc48 (diff) | |
parent | 40edf4e91558cffd83d9015a2cf4a16360e27855 (diff) | |
download | mana-client-fa2f3ac593a792c32095c2e885665ec91bb4019d.tar.gz mana-client-fa2f3ac593a792c32095c2e885665ec91bb4019d.tar.bz2 mana-client-fa2f3ac593a792c32095c2e885665ec91bb4019d.tar.xz mana-client-fa2f3ac593a792c32095c2e885665ec91bb4019d.zip |
Merged with Aethyra master as of 2009-02-09
Conflicts:
A lot of files...
Diffstat (limited to 'src/gui/popupmenu.cpp')
-rw-r--r-- | src/gui/popupmenu.cpp | 25 |
1 files changed, 10 insertions, 15 deletions
diff --git a/src/gui/popupmenu.cpp b/src/gui/popupmenu.cpp index 8cb22c55..be5252f7 100644 --- a/src/gui/popupmenu.cpp +++ b/src/gui/popupmenu.cpp @@ -20,9 +20,6 @@ */ #include <cassert> -#include <iostream> - -#include <guichan/focushandler.hpp> #include "browserbox.h" #include "chat.h" @@ -43,7 +40,6 @@ #include "../net/protocol.h" #include "../resources/itemdb.h" -#include "../resources/iteminfo.h" #include "../utils/gettext.h" #include "../utils/strprintf.h" @@ -80,27 +76,27 @@ void PopupMenu::showPopup(int x, int y, Being *being) // Players can be traded with. Later also attack, follow and // add as buddy will be options in this menu. const std::string &name = being->getName(); - mBrowserBox->addRow(_("@@trade|Trade With ") + name + "@@"); - mBrowserBox->addRow(_("@@attack|Attack ") + name + "@@"); + mBrowserBox->addRow(strprintf(_("@@trade|Trade With %s@@"), name.c_str())); + mBrowserBox->addRow(strprintf(_("@@attack|Attack %s@@"), name.c_str())); mBrowserBox->addRow("##3---"); switch (player_relations.getRelation(name)) { case PlayerRelation::NEUTRAL: - mBrowserBox->addRow(_("@@friend|Befriend ") + name + "@@"); + mBrowserBox->addRow(strprintf(_("@@friend|Befriend %s@@"), name.c_str())); case PlayerRelation::FRIEND: - mBrowserBox->addRow(_("@@disregard|Disregard ") + name + "@@"); - mBrowserBox->addRow(_("@@ignore|Ignore ") + name + "@@"); + mBrowserBox->addRow(strprintf(_("@@disregard|Disregard %s@@"), name.c_str())); + mBrowserBox->addRow(strprintf(_("@@ignore|Ignore %s@@"), name.c_str())); break; case PlayerRelation::DISREGARDED: - mBrowserBox->addRow(_("@@unignore|Un-Ignore ") + name + "@@"); - mBrowserBox->addRow(_("@@ignore|Completely ignore ") + name + "@@"); + mBrowserBox->addRow(strprintf(_("@@unignore|Un-Ignore %s@@"), name.c_str())); + mBrowserBox->addRow(strprintf(_("@@ignore|Completely ignore %s@@"), name.c_str())); break; case PlayerRelation::IGNORED: - mBrowserBox->addRow(_("@@unignore|Un-Ignore ") + name + "@@"); + mBrowserBox->addRow(strprintf(_("@@unignore|Un-Ignore %s@@"), name.c_str())); break; } @@ -108,8 +104,7 @@ void PopupMenu::showPopup(int x, int y, Being *being) //mBrowserBox->addRow(_("@@buddy|Add ") + name + " to Buddy List@@"); mBrowserBox->addRow("##3---"); - mBrowserBox->addRow(_("@@party-invite|Invite ") + name + - " to party@@"); + mBrowserBox->addRow(strprintf(_("@@party-invite|Invite %s to party@@"), name.c_str())); } break; @@ -254,7 +249,7 @@ void PopupMenu::handleLink(const std::string& link) else if (link == "chat") { - chatWindow->addItemText(mItem->getId(), mItem->getInfo().getName()); + chatWindow->addItemText(mItem->getInfo().getName()); } else if (link == "drop") |