summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/actions/actiondef.h7
-rw-r--r--src/actions/actions.cpp2
-rw-r--r--src/actions/commands.cpp18
-rw-r--r--src/gui/popups/itempopup.cpp2
-rw-r--r--src/gui/windows/itemamountwindow.cpp2
-rw-r--r--src/gui/windows/npcdialog.cpp8
-rw-r--r--src/localconsts.h5
7 files changed, 28 insertions, 16 deletions
diff --git a/src/actions/actiondef.h b/src/actions/actiondef.h
index c8b57e9e4..10388b1dc 100644
--- a/src/actions/actiondef.h
+++ b/src/actions/actiondef.h
@@ -27,6 +27,13 @@
#include "input/inputmanager.h"
#define impHandler(name) bool name(InputEvent &event)
+
+#ifdef EATHENA_SUPPORT
+#define impHandlerE(name) bool name(InputEvent &event)
+#else // EATHENA_SUPPORT
+#define impHandlerE(name) bool name(InputEvent &event A_UNUSED)
+#endif // EATHENA_SUPPORT
+
#define impHandler0(name) bool name(InputEvent &event A_UNUSED)
#define impHandlerVoid(name) bool name(InputEvent &event A_UNUSED) \
{ \
diff --git a/src/actions/actions.cpp b/src/actions/actions.cpp
index 4e98517a1..a51dab201 100644
--- a/src/actions/actions.cpp
+++ b/src/actions/actions.cpp
@@ -1699,7 +1699,7 @@ impHandler0(testInfo)
return false;
}
-impHandler(craftKey)
+impHandlerE(craftKey)
{
#ifdef EATHENA_SUPPORT
const int slot = (event.action - InputAction::CRAFT_1);
diff --git a/src/actions/commands.cpp b/src/actions/commands.cpp
index 5fe0f1b08..b9894aba6 100644
--- a/src/actions/commands.cpp
+++ b/src/actions/commands.cpp
@@ -896,7 +896,7 @@ impHandler(serverUnIgnoreWhisper)
return false;
}
-impHandler(setHomunculusName)
+impHandlerE(setHomunculusName)
{
#ifdef EATHENA_SUPPORT
const std::string args = event.args;
@@ -960,7 +960,7 @@ impHandler(warp)
return false;
}
-impHandler(homunTalk)
+impHandlerE(homunTalk)
{
#ifdef EATHENA_SUPPORT
if (!serverFeatures || !serverFeatures->haveTalkPet())
@@ -978,7 +978,7 @@ impHandler(homunTalk)
return false;
}
-impHandler(homunEmote)
+impHandlerE(homunEmote)
{
#ifdef EATHENA_SUPPORT
if (!serverFeatures || !serverFeatures->haveTalkPet())
@@ -1000,7 +1000,7 @@ impHandler(homunEmote)
return false;
}
-impHandler(commandHomunEmote)
+impHandlerE(commandHomunEmote)
{
#ifdef EATHENA_SUPPORT
if (!serverFeatures || !serverFeatures->haveTalkPet())
@@ -1016,7 +1016,7 @@ impHandler(commandHomunEmote)
return false;
}
-impHandler(createPublicChatRoom)
+impHandlerE(createPublicChatRoom)
{
#ifdef EATHENA_SUPPORT
if (!chatHandler || event.args.empty())
@@ -1028,7 +1028,7 @@ impHandler(createPublicChatRoom)
#endif
}
-impHandler(joinChatRoom)
+impHandlerE(joinChatRoom)
{
#ifdef EATHENA_SUPPORT
if (!chatHandler)
@@ -1175,7 +1175,7 @@ impHandler(skill)
return true;
}
-impHandler(craft)
+impHandlerE(craft)
{
#ifdef EATHENA_SUPPORT
const std::string args = event.args;
@@ -1585,7 +1585,7 @@ impHandler(commandGuildRecall)
return true;
}
-impHandler(mailTo)
+impHandlerE(mailTo)
{
#ifdef EATHENA_SUPPORT
if (!mailWindow)
@@ -1597,7 +1597,7 @@ impHandler(mailTo)
#endif
}
-impHandler(adoptChild)
+impHandlerE(adoptChild)
{
#ifdef EATHENA_SUPPORT
const std::string nick = getNick(event);
diff --git a/src/gui/popups/itempopup.cpp b/src/gui/popups/itempopup.cpp
index c1d414539..04c786b4a 100644
--- a/src/gui/popups/itempopup.cpp
+++ b/src/gui/popups/itempopup.cpp
@@ -159,7 +159,7 @@ void ItemPopup::setItem(const ItemInfo &item,
const ItemColor color,
const bool showImage,
int id,
- const int *const cards)
+ const int *const cards A_TMWA_UNUSED)
{
if (!mIcon || (item.getName() == mLastName && color == mLastColor
&& id == mLastId))
diff --git a/src/gui/windows/itemamountwindow.cpp b/src/gui/windows/itemamountwindow.cpp
index 02c94931e..70a69d0ed 100644
--- a/src/gui/windows/itemamountwindow.cpp
+++ b/src/gui/windows/itemamountwindow.cpp
@@ -471,7 +471,7 @@ void ItemAmountWindow::showWindow(const Usage usage,
Window *const parent,
Item *const item,
int maxRange,
- int tag)
+ int tag A_TMWA_UNUSED)
{
if (!item)
return;
diff --git a/src/gui/windows/npcdialog.cpp b/src/gui/windows/npcdialog.cpp
index 69f024f50..90fbebebc 100644
--- a/src/gui/windows/npcdialog.cpp
+++ b/src/gui/windows/npcdialog.cpp
@@ -811,7 +811,7 @@ void NpcDialog::itemIndexRequest(const int size)
buildLayout();
}
-void NpcDialog::itemCraftRequest(const int size)
+void NpcDialog::itemCraftRequest(const int size A_TMWA_UNUSED)
{
#ifdef EATHENA_SUPPORT
mActionState = NPC_ACTION_INPUT;
@@ -1390,9 +1390,9 @@ std::string NpcDialog::complexItemToStr(const ComplexItem *const item)
return str;
}
-void NpcDialog::addCraftItem(Item *const item,
- const int amount,
- const int slot)
+void NpcDialog::addCraftItem(Item *const item A_TMWA_UNUSED,
+ const int amount A_TMWA_UNUSED,
+ const int slot A_TMWA_UNUSED)
{
if (mInputState != NPC_INPUT_ITEM_CRAFT)
return;
diff --git a/src/localconsts.h b/src/localconsts.h
index eeb1d657e..4a79f61b0 100644
--- a/src/localconsts.h
+++ b/src/localconsts.h
@@ -88,6 +88,11 @@
#define A_UNUSED __attribute__ ((unused))
#define A_WARN_UNUSED __attribute__ ((warn_unused_result))
#define DEPRECATED __attribute__ ((deprecated))
+#ifndef EATHENA_SUPPORT
+#define A_TMWA_UNUSED __attribute__ ((unused))
+#else // EATHENA_SUPPORT
+#define A_TMWA_UNUSED
+#endif // EATHENA_SUPPORT
#ifdef __native_client__
#define restrict