diff --git a/src/xbus/plugin.cpp b/src/xbus/plugin.cpp index f3c35bc8b..91d45a52f 100644 --- a/src/xbus/plugin.cpp +++ b/src/xbus/plugin.cpp @@ -12,4 +12,10 @@ namespace XBus { } + void CPlugin::startServer(const QString &address) + { + Q_ASSERT(! m_server); + m_server = new BlackCore::CDBusServer(address, this); + } + } diff --git a/src/xbus/plugin.h b/src/xbus/plugin.h index 85e3703a1..4730c7c63 100644 --- a/src/xbus/plugin.h +++ b/src/xbus/plugin.h @@ -10,7 +10,12 @@ //! \namespace XBus -#include +#define NOMINMAX + +#pragma push_macro("interface") +#undef interface +#include "blackcore/dbus_server.h" +#pragma pop_macro("interface") namespace XBus { @@ -25,6 +30,9 @@ namespace XBus CPlugin(); private: + BlackCore::CDBusServer *m_server = nullptr; + + void startServer(const QString &address); }; } diff --git a/src/xbus/xbus.pro b/src/xbus/xbus.pro index b1d4cd361..25fe137a3 100644 --- a/src/xbus/xbus.pro +++ b/src/xbus/xbus.pro @@ -6,7 +6,7 @@ QT += core gui widgets dbus network TEMPLATE = lib CONFIG += shared -CONFIG += blackmisc +CONFIG += blackmisc blackcore LIBS += -lXPLM @@ -17,6 +17,7 @@ SOURCES += *.cpp HEADERS += *.h #win32:!win32-g++*: PRE_TARGETDEPS += ../../../../lib/blackmisc.lib +#win32:!win32-g++*: PRE_TARGETDEPS += ../../../../lib/blackcore.lib # Required by X-Plane SDK