From f3fb75f3dfe916b95a0407fc7f680b954ba77504 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Tue, 23 Sep 2014 15:23:12 +0300 Subject: Add into mercenary context menu option to fire it. --- src/gui/popups/popupmenu.cpp | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'src/gui/popups/popupmenu.cpp') diff --git a/src/gui/popups/popupmenu.cpp b/src/gui/popups/popupmenu.cpp index 0af61c219..6cfecae78 100644 --- a/src/gui/popups/popupmenu.cpp +++ b/src/gui/popups/popupmenu.cpp @@ -71,6 +71,7 @@ #include "net/chathandler.h" #include "net/guildhandler.h" #include "net/inventoryhandler.h" +#include "net/mercenaryhandler.h" #include "net/net.h" #include "net/npchandler.h" #include "net/partyhandler.h" @@ -301,6 +302,13 @@ void PopupMenu::showPopup(const int x, const int y, const Being *const being) break; } + case ActorType::Mercenary: + // TRANSLATORS: popup menu item + // TRANSLATORS: fire mercenary + mBrowserBox->addRow("fire mercenary", _("Fire")); + mBrowserBox->addRow("##3---"); + break; + case ActorType::Avatar: case ActorType::Unknown: case ActorType::FloorItem: @@ -1828,6 +1836,10 @@ void PopupMenu::handleLink(const std::string &link, if (chat) chatHandler->joinChat(chat, ""); } + else if (link == "fire mercenary") + { + mercenaryHandler->fire(); + } else if (!link.compare(0, 10, "guild-pos-")) { if (localPlayer) -- cgit v1.2.3-70-g09d2