summaryrefslogtreecommitdiff
path: root/src/gui/popups/popupmenu.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2015-04-18 00:00:46 +0300
committerAndrei Karas <akaras@inbox.ru>2015-04-18 00:00:46 +0300
commit129f749d057e3b96161630934da7b2d89dec3c71 (patch)
tree1a11c98aaf08a46d544e9b3acf3910a560546c8b /src/gui/popups/popupmenu.cpp
parent39ab9ebf7464f77f079a8edecd3f43870245b8ee (diff)
downloadmanaplus-129f749d057e3b96161630934da7b2d89dec3c71.tar.gz
manaplus-129f749d057e3b96161630934da7b2d89dec3c71.tar.bz2
manaplus-129f749d057e3b96161630934da7b2d89dec3c71.tar.xz
manaplus-129f749d057e3b96161630934da7b2d89dec3c71.zip
Add eathena defines into being.
Diffstat (limited to 'src/gui/popups/popupmenu.cpp')
-rw-r--r--src/gui/popups/popupmenu.cpp8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/gui/popups/popupmenu.cpp b/src/gui/popups/popupmenu.cpp
index b16dd2ff4..b81ab29dd 100644
--- a/src/gui/popups/popupmenu.cpp
+++ b/src/gui/popups/popupmenu.cpp
@@ -234,7 +234,9 @@ void PopupMenu::showPopup(const int x, const int y, const Being *const being)
mBrowserBox->addRow("/navigateto 'NAME'", _("Move"));
addPlayerMisc();
addBuySell(being);
+#ifdef EATHENA_SUPPORT
addChat(being);
+#endif
break;
}
@@ -266,7 +268,9 @@ void PopupMenu::showPopup(const int x, const int y, const Being *const being)
// TRANSLATORS: popup menu item
// TRANSLATORS: add comment to npc
mBrowserBox->addRow("addcomment", _("Add comment"));
+#ifdef EATHENA_SUPPORT
addChat(being);
+#endif
break;
case ActorType::Monster:
@@ -1407,13 +1411,13 @@ void PopupMenu::handleLink(const std::string &link,
if (Widget::widgetExists(mWindow))
mWindow->setSticky(true);
}
+#ifdef EATHENA_SUPPORT
else if (link == "join chat" && being)
{
const ChatObject *const chat = being->getChat();
if (chat)
chatHandler->joinChat(chat, "");
}
-#ifdef EATHENA_SUPPORT
else if (link == "fire mercenary")
{
mercenaryHandler->fire();
@@ -2443,6 +2447,7 @@ void PopupMenu::addParty(const std::string &nick)
}
}
+#ifdef EATHENA_SUPPORT
void PopupMenu::addChat(const Being *const being)
{
if (!being)
@@ -2457,6 +2462,7 @@ void PopupMenu::addChat(const Being *const being)
mBrowserBox->addRow("##3---");
}
}
+#endif
void PopupMenu::addPlayerMisc()
{