diff options
author | Andrei Karas <akaras@inbox.ru> | 2015-02-16 21:26:24 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2015-02-16 21:26:24 +0300 |
commit | c3be771906112df05821dc82539fdca2bf3d7991 (patch) | |
tree | e086c35abaa0cae75c1543eb22dbff844e0671a8 | |
parent | cd25589ba6143591389095eb25a260e350edc699 (diff) | |
download | ManaVerse-c3be771906112df05821dc82539fdca2bf3d7991.tar.gz ManaVerse-c3be771906112df05821dc82539fdca2bf3d7991.tar.bz2 ManaVerse-c3be771906112df05821dc82539fdca2bf3d7991.tar.xz ManaVerse-c3be771906112df05821dc82539fdca2bf3d7991.zip |
Build buyingstoreslotslistener only if eathena support enabled.
-rw-r--r-- | src/CMakeLists.txt | 4 | ||||
-rw-r--r-- | src/Makefile.am | 4 | ||||
-rw-r--r-- | src/gui/windows/shopwindow.cpp | 8 | ||||
-rw-r--r-- | src/gui/windows/shopwindow.h | 10 | ||||
-rw-r--r-- | src/listeners/buyingstoreslotslistener.h | 3 |
5 files changed, 16 insertions, 13 deletions
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index f023a835c..f1f186b3d 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -812,8 +812,6 @@ SET(SRCS listeners/awaylistener.cpp listeners/awaylistener.h listeners/baselistener.hpp - listeners/buyingstoreslotslistener.cpp - listeners/buyingstoreslotslistener.h listeners/charrenamelistener.cpp listeners/charrenamelistener.h actormanager.cpp @@ -1414,6 +1412,8 @@ SET(SRCS_EATHENA listeners/banklistener.h listeners/buyingstoremodelistener.cpp listeners/buyingstoremodelistener.h + listeners/buyingstoreslotslistener.cpp + listeners/buyingstoreslotslistener.h net/eathena/adminhandler.cpp net/eathena/adminhandler.h net/eathena/auctionhandler.cpp diff --git a/src/Makefile.am b/src/Makefile.am index 2a7c7ea97..5a646a7bb 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -941,8 +941,6 @@ manaplus_SOURCES += gui/widgets/avatarlistbox.cpp \ listeners/awaylistener.cpp \ listeners/awaylistener.h \ listeners/baselistener.hpp \ - listeners/buyingstoreslotslistener.cpp \ - listeners/buyingstoreslotslistener.h \ listeners/charrenamelistener.cpp \ listeners/charrenamelistener.h \ actormanager.cpp \ @@ -1350,6 +1348,8 @@ manaplus_SOURCES += gui/windows/bankwindow.cpp \ listeners/banklistener.h \ listeners/buyingstoremodelistener.cpp \ listeners/buyingstoremodelistener.h \ + listeners/buyingstoreslotslistener.cpp \ + listeners/buyingstoreslotslistener.h \ net/eathena/adminhandler.cpp \ net/eathena/adminhandler.h \ net/eathena/auctionhandler.cpp \ diff --git a/src/gui/windows/shopwindow.cpp b/src/gui/windows/shopwindow.cpp index 32580454d..c4795dd9e 100644 --- a/src/gui/windows/shopwindow.cpp +++ b/src/gui/windows/shopwindow.cpp @@ -84,14 +84,14 @@ ShopWindow::DialogList ShopWindow::instances; ShopWindow::ShopWindow() : // TRANSLATORS: shop window name Window(_("Personal Shop"), false, nullptr, "shop.xml"), - ActionListener(), - SelectionListener(), VendingModeListener(), VendingSlotsListener(), #ifdef EATHENA_SUPPORT BuyingStoreModeListener(), -#endif BuyingStoreSlotsListener(), +#endif + ActionListener(), + SelectionListener(), // TRANSLATORS: shop window button mCloseButton(new Button(this, _("Close"), "close", this)), mBuyShopItems(new ShopItems), @@ -1074,13 +1074,13 @@ void ShopWindow::setShopName(const std::string &name) updateShopName(); } +#ifdef EATHENA_SUPPORT void ShopWindow::buyingStoreSlotsChanged(const int slots) { mBuyShopSize = slots; updateButtonsAndLabels(); } -#ifdef EATHENA_SUPPORT void ShopWindow::buyingStoreEnabled(const bool b) { mEnableBuyingStore = b; diff --git a/src/gui/windows/shopwindow.h b/src/gui/windows/shopwindow.h index 8cf1cecd5..500d67727 100644 --- a/src/gui/windows/shopwindow.h +++ b/src/gui/windows/shopwindow.h @@ -47,14 +47,14 @@ class TabStrip; * \ingroup Interface */ class ShopWindow final : public Window, - public ActionListener, - public SelectionListener, public VendingModeListener, public VendingSlotsListener, #ifdef EATHENA_SUPPORT public BuyingStoreModeListener, + public BuyingStoreSlotsListener, #endif - public BuyingStoreSlotsListener + public ActionListener, + public SelectionListener { public: enum ShopMode @@ -149,12 +149,12 @@ class ShopWindow final : public Window, void vendingSlotsChanged(const int slots) override final; - void buyingStoreSlotsChanged(const int slots) override final; - void vendingEnabled(const bool b) override final; #ifdef EATHENA_SUPPORT void buyingStoreEnabled(const bool b) override final; + + void buyingStoreSlotsChanged(const int slots) override final; #endif void setShopName(const std::string &name); diff --git a/src/listeners/buyingstoreslotslistener.h b/src/listeners/buyingstoreslotslistener.h index dc180a9cc..61b9dd454 100644 --- a/src/listeners/buyingstoreslotslistener.h +++ b/src/listeners/buyingstoreslotslistener.h @@ -21,6 +21,8 @@ #ifndef LISTENERS_BUYINGSTORESLOTSLISTENER_H #define LISTENERS_BUYINGSTORESLOTSLISTENER_H +#ifdef EATHENA_SUPPORT + #include "listeners/baselistener.hpp" #include "localconsts.h" @@ -35,4 +37,5 @@ class BuyingStoreSlotsListener notfinal defineListenerHeader(BuyingStoreSlotsListener) }; +#endif // EATHENA_SUPPORT #endif // LISTENERS_BUYINGSTORESLOTSLISTENER_H |