diff --git a/doric-Qt/example/app/app.pro b/doric-Qt/example/app/app.pro index 7d205552..f1227192 100644 --- a/doric-Qt/example/app/app.pro +++ b/doric-Qt/example/app/app.pro @@ -28,26 +28,14 @@ else: unix:!android: target.path = /opt/$${TARGET}/bin !isEmpty(target.path): INSTALLS += target win32:CONFIG(debug, debug|release): { - QMAKE_CFLAGS_DEBUG += -MTd - QMAKE_CXXFLAGS_DEBUG += -MTd - LIBS += -lwinmm LIBS += -lAdvapi32 LIBS += -lDbghelp - - LIBS += -L$$PWD/../../v8/v8/win32/debug/ - LIBS += -lv8_monolith } else:win32:CONFIG(release, debug|release): { - QMAKE_CFLAGS_RELEASE += -MT - QMAKE_CXXFLAGS_RELEASE += -MT - LIBS += -lwinmm LIBS += -lAdvapi32 LIBS += -lDbghelp - - LIBS += -L$$PWD/../../v8/v8/win32/release/ - LIBS += -lv8_monolith } else:unix: { LIBS += -L$$PWD/../../v8/v8/darwin/release/ diff --git a/doric-Qt/example/doric/DoricContext.h b/doric-Qt/example/doric/DoricContext.h index d9bd9422..7bcc40bd 100644 --- a/doric-Qt/example/doric/DoricContext.h +++ b/doric-Qt/example/doric/DoricContext.h @@ -4,12 +4,14 @@ #include #include +#include "DoricExport.h" + #include "DoricInterfaceDriver.h" class DoricViewNode; class DoricRootNode; -class DoricContext { +class DORIC_EXPORT DoricContext { private: QString mContextId; QMap mPluginMap; diff --git a/doric-Qt/example/doric/DoricContextManager.h b/doric-Qt/example/doric/DoricContextManager.h index b958698d..13a773b2 100644 --- a/doric-Qt/example/doric/DoricContextManager.h +++ b/doric-Qt/example/doric/DoricContextManager.h @@ -3,9 +3,11 @@ #include +#include "DoricExport.h" + #include "DoricContext.h" -class DoricContextManager { +class DORIC_EXPORT DoricContextManager { private: static DoricContextManager *local_instance; DoricContextManager() {} diff --git a/doric-Qt/example/doric/DoricExport.h b/doric-Qt/example/doric/DoricExport.h new file mode 100644 index 00000000..4e7c835a --- /dev/null +++ b/doric-Qt/example/doric/DoricExport.h @@ -0,0 +1,10 @@ +#ifndef DORICEXPORT_H +#define DORICEXPORT_H + +#if defined(DORIC_LIBRARY) +# define DORIC_EXPORT Q_DECL_EXPORT +#else +# define DORIC_EXPORT Q_DECL_IMPORT +#endif + +#endif // DORICEXPORT_H diff --git a/doric-Qt/example/doric/DoricNativeDriver.h b/doric-Qt/example/doric/DoricNativeDriver.h index 183a429f..7dfd8e3b 100644 --- a/doric-Qt/example/doric/DoricNativeDriver.h +++ b/doric-Qt/example/doric/DoricNativeDriver.h @@ -3,10 +3,12 @@ #include +#include "DoricExport.h" + #include "DoricInterfaceDriver.h" #include "engine/DoricJSEngine.h" -class DoricNativeDriver : public DoricInterfaceDriver { +class DORIC_EXPORT DoricNativeDriver : public DoricInterfaceDriver { private: static DoricNativeDriver *local_instance; DoricNativeDriver() {} diff --git a/doric-Qt/example/doric/DoricPanel.h b/doric-Qt/example/doric/DoricPanel.h index eb8b45ad..a9a2e461 100644 --- a/doric-Qt/example/doric/DoricPanel.h +++ b/doric-Qt/example/doric/DoricPanel.h @@ -3,9 +3,11 @@ #include +#include "DoricExport.h" + #include "DoricContext.h" -class DoricPanel { +class DORIC_EXPORT DoricPanel { private: DoricContext *mContext; int renderedWidth = -1; diff --git a/doric-Qt/example/doric/DoricRegistry.h b/doric-Qt/example/doric/DoricRegistry.h index 71c93c5e..067844f0 100644 --- a/doric-Qt/example/doric/DoricRegistry.h +++ b/doric-Qt/example/doric/DoricRegistry.h @@ -4,11 +4,13 @@ #include #include +#include "DoricExport.h" + #include "utils/DoricObjectFactory.h" class DoricLibrary; -class DoricRegistry { +class DORIC_EXPORT DoricRegistry { private: static DoricRegistry *local_instance; diff --git a/doric-Qt/example/doric/async/DoricAsyncResult.h b/doric-Qt/example/doric/async/DoricAsyncResult.h index 9228a6ba..02843094 100644 --- a/doric-Qt/example/doric/async/DoricAsyncResult.h +++ b/doric-Qt/example/doric/async/DoricAsyncResult.h @@ -3,12 +3,14 @@ #include +#include "DoricExport.h" + #include "DoricCallback.h" #include "DoricSettableFuture.h" static QJSValue EMPTY(QJSValue::NullValue); -class DoricAsyncResult { +class DORIC_EXPORT DoricAsyncResult { private: QJSValue result = EMPTY; DoricCallback *callback; diff --git a/doric-Qt/example/doric/async/DoricSettableFuture.h b/doric-Qt/example/doric/async/DoricSettableFuture.h index fce4f8ea..10f6961a 100644 --- a/doric-Qt/example/doric/async/DoricSettableFuture.h +++ b/doric-Qt/example/doric/async/DoricSettableFuture.h @@ -3,9 +3,11 @@ #include +#include "DoricExport.h" + #include "utils/DoricCountDownLatch.h" -class DoricSettableFuture { +class DORIC_EXPORT DoricSettableFuture { private: QJSValue mResult; DoricCountDownLatch *mReadyLatch = new DoricCountDownLatch(); diff --git a/doric-Qt/example/doric/doric.pro b/doric-Qt/example/doric/doric.pro index 63f46d77..8af9bf01 100644 --- a/doric-Qt/example/doric/doric.pro +++ b/doric-Qt/example/doric/doric.pro @@ -4,14 +4,13 @@ CONFIG += c++14 TARGET = DoricCore TEMPLATE = lib -CONFIG += staticlib # The following define makes your compiler emit warnings if you use # any Qt feature that has been marked deprecated (the exact warnings # depend on your compiler). Refer to the documentation for the # deprecated API to know how to port your code away from it. DEFINES += QT_DEPRECATED_WARNINGS -DEFINES += V8_COMPRESS_POINTERS +DEFINES += DORIC_LIBRARY # You can also make your code fail to compile if it uses deprecated APIs. # In order to do so, uncomment the following line. @@ -92,6 +91,7 @@ HEADERS += \ Doric.h \ DoricContext.h \ DoricContextManager.h \ + DoricExport.h \ DoricInterfaceDriver.h \ DoricLibrary.h \ DoricNativeDriver.h \ diff --git a/doric-Qt/example/doric/engine/DoricBridgeExtension.h b/doric-Qt/example/doric/engine/DoricBridgeExtension.h index f31d098a..ebf30c50 100644 --- a/doric-Qt/example/doric/engine/DoricBridgeExtension.h +++ b/doric-Qt/example/doric/engine/DoricBridgeExtension.h @@ -4,7 +4,9 @@ #include #include -class DoricBridgeExtension : public QObject { +#include "DoricExport.h" + +class DORIC_EXPORT DoricBridgeExtension : public QObject { Q_OBJECT public: explicit DoricBridgeExtension(QObject *parent = nullptr); diff --git a/doric-Qt/example/doric/engine/DoricJSEngine.h b/doric-Qt/example/doric/engine/DoricJSEngine.h index f8f3909c..9fb10e23 100644 --- a/doric-Qt/example/doric/engine/DoricJSEngine.h +++ b/doric-Qt/example/doric/engine/DoricJSEngine.h @@ -4,10 +4,12 @@ #include #include +#include "DoricExport.h" + #include "../DoricRegistry.h" #include "DoricInterfaceJSE.h" -class DoricJSEngine : public QObject { +class DORIC_EXPORT DoricJSEngine : public QObject { Q_OBJECT private: DoricInterfaceJSE *mJSE; diff --git a/doric-Qt/example/doric/engine/DoricNativeEmpty.h b/doric-Qt/example/doric/engine/DoricNativeEmpty.h index 34ab659c..6eb6cbd9 100644 --- a/doric-Qt/example/doric/engine/DoricNativeEmpty.h +++ b/doric-Qt/example/doric/engine/DoricNativeEmpty.h @@ -3,7 +3,9 @@ #include -class DoricNativeEmpty : public QObject { +#include "DoricExport.h" + +class DORIC_EXPORT DoricNativeEmpty : public QObject { Q_OBJECT public: diff --git a/doric-Qt/example/doric/engine/DoricNativeJSE.h b/doric-Qt/example/doric/engine/DoricNativeJSE.h index a314696f..0324a6e2 100644 --- a/doric-Qt/example/doric/engine/DoricNativeJSE.h +++ b/doric-Qt/example/doric/engine/DoricNativeJSE.h @@ -1,13 +1,15 @@ #ifndef NATIVE_JSE_H #define NATIVE_JSE_H +#include "DoricExport.h" + #include "DoricInterfaceJSE.h" #include "native/NativeExecutor.h" #include "v8/V8Executor.h" enum class JSEType { V8, Native }; -class DoricNativeJSE : public DoricInterfaceJSE { +class DORIC_EXPORT DoricNativeJSE : public DoricInterfaceJSE { private: JSEType mType; diff --git a/doric-Qt/example/doric/engine/DoricNativeLog.h b/doric-Qt/example/doric/engine/DoricNativeLog.h index 89fdad5e..eb72efbf 100644 --- a/doric-Qt/example/doric/engine/DoricNativeLog.h +++ b/doric-Qt/example/doric/engine/DoricNativeLog.h @@ -3,7 +3,9 @@ #include -class DoricNativeLog : public QObject { +#include "DoricExport.h" + +class DORIC_EXPORT DoricNativeLog : public QObject { Q_OBJECT public: diff --git a/doric-Qt/example/doric/engine/DoricNativeRequire.h b/doric-Qt/example/doric/engine/DoricNativeRequire.h index e033e558..247e18aa 100644 --- a/doric-Qt/example/doric/engine/DoricNativeRequire.h +++ b/doric-Qt/example/doric/engine/DoricNativeRequire.h @@ -3,7 +3,9 @@ #include -class DoricNativeRequire : public QObject { +#include "DoricExport.h" + +class DORIC_EXPORT DoricNativeRequire : public QObject { Q_OBJECT public: diff --git a/doric-Qt/example/doric/engine/DoricTimerExtension.h b/doric-Qt/example/doric/engine/DoricTimerExtension.h index 79a29e95..eb4d1fc3 100644 --- a/doric-Qt/example/doric/engine/DoricTimerExtension.h +++ b/doric-Qt/example/doric/engine/DoricTimerExtension.h @@ -4,7 +4,9 @@ #include #include -class DoricTimerExtension : public QObject { +#include "DoricExport.h" + +class DORIC_EXPORT DoricTimerExtension : public QObject { Q_OBJECT private: diff --git a/doric-Qt/example/doric/plugin/DoricModalPlugin.h b/doric-Qt/example/doric/plugin/DoricModalPlugin.h index 780392df..78925839 100644 --- a/doric-Qt/example/doric/plugin/DoricModalPlugin.h +++ b/doric-Qt/example/doric/plugin/DoricModalPlugin.h @@ -1,9 +1,11 @@ #ifndef DORICMODALPLUGIN_H #define DORICMODALPLUGIN_H +#include "DoricExport.h" + #include "DoricNativePlugin.h" -class DoricModalPlugin : public DoricNativePlugin { +class DORIC_EXPORT DoricModalPlugin : public DoricNativePlugin { Q_OBJECT public: using DoricNativePlugin::DoricNativePlugin; diff --git a/doric-Qt/example/doric/plugin/DoricNetworkPlugin.h b/doric-Qt/example/doric/plugin/DoricNetworkPlugin.h index a6044312..4779a465 100644 --- a/doric-Qt/example/doric/plugin/DoricNetworkPlugin.h +++ b/doric-Qt/example/doric/plugin/DoricNetworkPlugin.h @@ -1,9 +1,11 @@ #ifndef DORICNETWORKPLUGIN_H #define DORICNETWORKPLUGIN_H +#include "DoricExport.h" + #include "DoricNativePlugin.h" -class DoricNetworkPlugin : public DoricNativePlugin { +class DORIC_EXPORT DoricNetworkPlugin : public DoricNativePlugin { Q_OBJECT public: using DoricNativePlugin::DoricNativePlugin; diff --git a/doric-Qt/example/doric/plugin/DoricPopoverPlugin.h b/doric-Qt/example/doric/plugin/DoricPopoverPlugin.h index 24ef0d14..8f4183a9 100644 --- a/doric-Qt/example/doric/plugin/DoricPopoverPlugin.h +++ b/doric-Qt/example/doric/plugin/DoricPopoverPlugin.h @@ -1,13 +1,15 @@ #ifndef DORICPOPOVERPLUGIN_H #define DORICPOPOVERPLUGIN_H -#include "DoricNativePlugin.h" - #include +#include "DoricExport.h" + +#include "DoricNativePlugin.h" + static QString TYPE = "popover"; -class DoricPopoverPlugin : public DoricNativePlugin { +class DORIC_EXPORT DoricPopoverPlugin : public DoricNativePlugin { Q_OBJECT public: using DoricNativePlugin::DoricNativePlugin; diff --git a/doric-Qt/example/doric/plugin/DoricShaderPlugin.h b/doric-Qt/example/doric/plugin/DoricShaderPlugin.h index 273295b0..c7186135 100644 --- a/doric-Qt/example/doric/plugin/DoricShaderPlugin.h +++ b/doric-Qt/example/doric/plugin/DoricShaderPlugin.h @@ -1,9 +1,11 @@ #ifndef SHADERPLUGIN_H #define SHADERPLUGIN_H +#include "DoricExport.h" + #include "DoricNativePlugin.h" -class DoricShaderPlugin : public DoricNativePlugin { +class DORIC_EXPORT DoricShaderPlugin : public DoricNativePlugin { Q_OBJECT public: using DoricNativePlugin::DoricNativePlugin; diff --git a/doric-Qt/example/doric/plugin/DoricStoragePlugin.h b/doric-Qt/example/doric/plugin/DoricStoragePlugin.h index 80ec2c92..a8e7265b 100644 --- a/doric-Qt/example/doric/plugin/DoricStoragePlugin.h +++ b/doric-Qt/example/doric/plugin/DoricStoragePlugin.h @@ -1,9 +1,11 @@ #ifndef DORICSTORAGEPLUGIN_H #define DORICSTORAGEPLUGIN_H +#include "DoricExport.h" + #include "DoricNativePlugin.h" -class DoricStoragePlugin : public DoricNativePlugin { +class DORIC_EXPORT DoricStoragePlugin : public DoricNativePlugin { Q_OBJECT private: static const QString PREF_NAME; diff --git a/doric-Qt/example/doric/shader/DoricGroupNode.h b/doric-Qt/example/doric/shader/DoricGroupNode.h index 6d565d32..b2a5e559 100644 --- a/doric-Qt/example/doric/shader/DoricGroupNode.h +++ b/doric-Qt/example/doric/shader/DoricGroupNode.h @@ -1,9 +1,11 @@ #ifndef DORICGROUPNODE_H #define DORICGROUPNODE_H +#include "DoricExport.h" + #include "DoricSuperNode.h" -class DoricGroupNode : public DoricSuperNode { +class DORIC_EXPORT DoricGroupNode : public DoricSuperNode { public: using DoricSuperNode::DoricSuperNode; diff --git a/doric-Qt/example/doric/shader/DoricHLayoutNode.h b/doric-Qt/example/doric/shader/DoricHLayoutNode.h index 7fdb7ef7..2773accf 100644 --- a/doric-Qt/example/doric/shader/DoricHLayoutNode.h +++ b/doric-Qt/example/doric/shader/DoricHLayoutNode.h @@ -1,10 +1,11 @@ #ifndef DORICHLAYOUTNODE_H #define DORICHLAYOUTNODE_H +#include "DoricExport.h" #include "DoricGroupNode.h" -class DoricHLayoutNode : public DoricGroupNode { +class DORIC_EXPORT DoricHLayoutNode : public DoricGroupNode { public: using DoricGroupNode::DoricGroupNode; diff --git a/doric-Qt/example/doric/shader/DoricImageNode.h b/doric-Qt/example/doric/shader/DoricImageNode.h index 6322c205..99aac71c 100644 --- a/doric-Qt/example/doric/shader/DoricImageNode.h +++ b/doric-Qt/example/doric/shader/DoricImageNode.h @@ -1,9 +1,11 @@ #ifndef DORICIMAGENODE_H #define DORICIMAGENODE_H +#include "DoricExport.h" + #include "DoricViewNode.h" -class DoricImageNode : public DoricViewNode { +class DORIC_EXPORT DoricImageNode : public DoricViewNode { public: using DoricViewNode::DoricViewNode; diff --git a/doric-Qt/example/doric/shader/DoricRootNode.h b/doric-Qt/example/doric/shader/DoricRootNode.h index 0499ef9c..8b9cef66 100644 --- a/doric-Qt/example/doric/shader/DoricRootNode.h +++ b/doric-Qt/example/doric/shader/DoricRootNode.h @@ -3,9 +3,11 @@ #include +#include "DoricExport.h" + #include "DoricStackNode.h" -class DoricRootNode : public DoricStackNode { +class DORIC_EXPORT DoricRootNode : public DoricStackNode { public: using DoricStackNode::DoricStackNode; diff --git a/doric-Qt/example/doric/shader/DoricScrollerNode.h b/doric-Qt/example/doric/shader/DoricScrollerNode.h index da651025..bf1842c3 100644 --- a/doric-Qt/example/doric/shader/DoricScrollerNode.h +++ b/doric-Qt/example/doric/shader/DoricScrollerNode.h @@ -1,9 +1,11 @@ #ifndef DORICSCROLLERNODE_H #define DORICSCROLLERNODE_H +#include "DoricExport.h" + #include "DoricSuperNode.h" -class DoricScrollerNode : public DoricSuperNode { +class DORIC_EXPORT DoricScrollerNode : public DoricSuperNode { private: DoricViewNode *mChildNode = nullptr; diff --git a/doric-Qt/example/doric/shader/DoricStackNode.h b/doric-Qt/example/doric/shader/DoricStackNode.h index 4b37203e..41b71123 100644 --- a/doric-Qt/example/doric/shader/DoricStackNode.h +++ b/doric-Qt/example/doric/shader/DoricStackNode.h @@ -1,9 +1,11 @@ #ifndef DORICSTACKNODE_H #define DORICSTACKNODE_H +#include "DoricExport.h" + #include "DoricGroupNode.h" -class DoricStackNode : public DoricGroupNode { +class DORIC_EXPORT DoricStackNode : public DoricGroupNode { public: using DoricGroupNode::DoricGroupNode; diff --git a/doric-Qt/example/doric/shader/DoricSuperNode.h b/doric-Qt/example/doric/shader/DoricSuperNode.h index 214bcd8e..e02f6208 100644 --- a/doric-Qt/example/doric/shader/DoricSuperNode.h +++ b/doric-Qt/example/doric/shader/DoricSuperNode.h @@ -3,9 +3,11 @@ #include +#include "DoricExport.h" + #include "DoricViewNode.h" -class DoricSuperNode : public DoricViewNode { +class DORIC_EXPORT DoricSuperNode : public DoricViewNode { private: QMap subNodes; diff --git a/doric-Qt/example/doric/shader/DoricTextNode.h b/doric-Qt/example/doric/shader/DoricTextNode.h index 19c0ab3e..68bfdb1a 100644 --- a/doric-Qt/example/doric/shader/DoricTextNode.h +++ b/doric-Qt/example/doric/shader/DoricTextNode.h @@ -1,9 +1,11 @@ #ifndef DORICTEXTNODE_H #define DORICTEXTNODE_H +#include "DoricExport.h" + #include "DoricViewNode.h" -class DoricTextNode : public DoricViewNode { +class DORIC_EXPORT DoricTextNode : public DoricViewNode { public: using DoricViewNode::DoricViewNode; diff --git a/doric-Qt/example/doric/shader/DoricVLayoutNode.h b/doric-Qt/example/doric/shader/DoricVLayoutNode.h index 8b21d601..dacc10d0 100644 --- a/doric-Qt/example/doric/shader/DoricVLayoutNode.h +++ b/doric-Qt/example/doric/shader/DoricVLayoutNode.h @@ -1,9 +1,11 @@ #ifndef DORICVLAYOUTNODE_H #define DORICVLAYOUTNODE_H +#include "DoricExport.h" + #include "DoricGroupNode.h" -class DoricVLayoutNode : public DoricGroupNode { +class DORIC_EXPORT DoricVLayoutNode : public DoricGroupNode { public: using DoricGroupNode::DoricGroupNode; diff --git a/doric-Qt/example/doric/shader/DoricViewNode.h b/doric-Qt/example/doric/shader/DoricViewNode.h index 80543b4b..74db1e3b 100644 --- a/doric-Qt/example/doric/shader/DoricViewNode.h +++ b/doric-Qt/example/doric/shader/DoricViewNode.h @@ -5,12 +5,14 @@ #include #include +#include "DoricExport.h" + #include "../utils/DoricContextHolder.h" #include "../utils/DoricLayouts.h" class DoricSuperNode; -class DoricViewNode : public DoricContextHolder { +class DORIC_EXPORT DoricViewNode : public DoricContextHolder { protected: QQuickItem *mView; diff --git a/doric-Qt/example/doric/shader/slider/DoricSlideItemNode.h b/doric-Qt/example/doric/shader/slider/DoricSlideItemNode.h index 6788ec57..c7dde437 100644 --- a/doric-Qt/example/doric/shader/slider/DoricSlideItemNode.h +++ b/doric-Qt/example/doric/shader/slider/DoricSlideItemNode.h @@ -1,9 +1,11 @@ #ifndef DORICSLIDEITEMNODE_H #define DORICSLIDEITEMNODE_H +#include "DoricExport.h" + #include "shader/DoricStackNode.h" -class DoricSlideItemNode : public DoricStackNode { +class DORIC_EXPORT DoricSlideItemNode : public DoricStackNode { public: using DoricStackNode::DoricStackNode; }; diff --git a/doric-Qt/example/doric/shader/slider/DoricSliderNode.h b/doric-Qt/example/doric/shader/slider/DoricSliderNode.h index b94d899a..314a2332 100644 --- a/doric-Qt/example/doric/shader/slider/DoricSliderNode.h +++ b/doric-Qt/example/doric/shader/slider/DoricSliderNode.h @@ -1,10 +1,12 @@ #ifndef DORICSLIDERNODE_H #define DORICSLIDERNODE_H +#include "DoricExport.h" + #include "DoricSlideItemNode.h" #include "shader/DoricSuperNode.h" -class DoricSliderNode : public DoricSuperNode { +class DORIC_EXPORT DoricSliderNode : public DoricSuperNode { private: int itemCount = 0; diff --git a/doric-Qt/example/doric/utils/DoricConstant.h b/doric-Qt/example/doric/utils/DoricConstant.h index dd329425..f1d953c6 100644 --- a/doric-Qt/example/doric/utils/DoricConstant.h +++ b/doric-Qt/example/doric/utils/DoricConstant.h @@ -3,7 +3,9 @@ #include -class DoricConstant { +#include "DoricExport.h" + +class DORIC_EXPORT DoricConstant { public: static const QString DORIC_BUNDLE_SANDBOX; diff --git a/doric-Qt/example/doric/utils/DoricContextHolder.h b/doric-Qt/example/doric/utils/DoricContextHolder.h index c12aa84e..c041860d 100644 --- a/doric-Qt/example/doric/utils/DoricContextHolder.h +++ b/doric-Qt/example/doric/utils/DoricContextHolder.h @@ -1,9 +1,11 @@ #ifndef DORICCONTEXTHOLDER_H #define DORICCONTEXTHOLDER_H +#include "DoricExport.h" + #include "../DoricContext.h" -class DoricContextHolder : public QObject { +class DORIC_EXPORT DoricContextHolder : public QObject { protected: DoricContext *mContext = NULL; diff --git a/doric-Qt/example/doric/utils/DoricDialogBridge.h b/doric-Qt/example/doric/utils/DoricDialogBridge.h index 24b926dc..ea904a12 100644 --- a/doric-Qt/example/doric/utils/DoricDialogBridge.h +++ b/doric-Qt/example/doric/utils/DoricDialogBridge.h @@ -3,7 +3,9 @@ #include -class DoricDialogBridge : public QObject { +#include "DoricExport.h" + +class DORIC_EXPORT DoricDialogBridge : public QObject { Q_OBJECT public: explicit DoricDialogBridge(QObject *parent = nullptr); diff --git a/doric-Qt/example/doric/utils/DoricImageBridge.h b/doric-Qt/example/doric/utils/DoricImageBridge.h index 57496f00..297365d1 100644 --- a/doric-Qt/example/doric/utils/DoricImageBridge.h +++ b/doric-Qt/example/doric/utils/DoricImageBridge.h @@ -3,7 +3,9 @@ #include -class DoricImageBridge : public QObject { +#include "DoricExport.h" + +class DORIC_EXPORT DoricImageBridge : public QObject { Q_OBJECT public: explicit DoricImageBridge(QObject *parent = nullptr); diff --git a/doric-Qt/example/doric/utils/DoricLayouts.h b/doric-Qt/example/doric/utils/DoricLayouts.h index 8508b2de..47558f62 100644 --- a/doric-Qt/example/doric/utils/DoricLayouts.h +++ b/doric-Qt/example/doric/utils/DoricLayouts.h @@ -3,7 +3,9 @@ #include -class DoricLayoutType { +#include "DoricExport.h" + +class DORIC_EXPORT DoricLayoutType { public: const static int DoricUndefined = 0; const static int DoricStack = 1; @@ -11,14 +13,14 @@ public: const static int DoricHLayout = 3; }; -class DoricLayoutSpec { +class DORIC_EXPORT DoricLayoutSpec { public: const static int DoricLayoutJust = 0; const static int DoricLayoutFit = 1; const static int DoricLayoutMost = 2; }; -class DoricGravity { +class DORIC_EXPORT DoricGravity { public: const static int DoricGravitySpecified = 1; const static int DoricGravityStart = 1 << 1; @@ -41,7 +43,7 @@ public: DoricGravityCenterX | DoricGravityCenterY; }; -class DoricLayouts : public QObject { +class DORIC_EXPORT DoricLayouts : public QObject { public: explicit DoricLayouts(QObject *parent = nullptr); diff --git a/doric-Qt/example/doric/utils/DoricMouseAreaBridge.h b/doric-Qt/example/doric/utils/DoricMouseAreaBridge.h index e2ef2a26..0ab0a4c0 100644 --- a/doric-Qt/example/doric/utils/DoricMouseAreaBridge.h +++ b/doric-Qt/example/doric/utils/DoricMouseAreaBridge.h @@ -4,7 +4,9 @@ #include #include -class DoricMouseAreaBridge : public QObject { +#include "DoricExport.h" + +class DORIC_EXPORT DoricMouseAreaBridge : public QObject { Q_OBJECT public: explicit DoricMouseAreaBridge(QObject *parent = nullptr); diff --git a/doric-Qt/example/doric/widget/flex/FlexLayout.h b/doric-Qt/example/doric/widget/flex/FlexLayout.h index 316fa0f7..a4162785 100644 --- a/doric-Qt/example/doric/widget/flex/FlexLayout.h +++ b/doric-Qt/example/doric/widget/flex/FlexLayout.h @@ -6,10 +6,12 @@ #include #include +#include "DoricExport.h" + #include "yoga/Yoga.h" #include "FlexLayoutConfig.h" -class FlexLayout : public QObject { +class DORIC_EXPORT FlexLayout : public QObject { Q_OBJECT Q_PROPERTY(int flexShrink READ getFlexShrink WRITE setFlexShrink) diff --git a/doric-Qt/example/doric/widget/flex/FlexLayoutConfig.h b/doric-Qt/example/doric/widget/flex/FlexLayoutConfig.h index b56ae395..34e2bf5b 100644 --- a/doric-Qt/example/doric/widget/flex/FlexLayoutConfig.h +++ b/doric-Qt/example/doric/widget/flex/FlexLayoutConfig.h @@ -4,9 +4,11 @@ #include #include +#include "DoricExport.h" + #include "yoga/Yoga.h" -class FlexLayoutConfig : public QObject { +class DORIC_EXPORT FlexLayoutConfig : public QObject { Q_OBJECT private: YGConfigRef config; diff --git a/doric-Qt/example/doric/widget/flex/FlexLayoutService.h b/doric-Qt/example/doric/widget/flex/FlexLayoutService.h index 860e3f09..6acbaf5a 100644 --- a/doric-Qt/example/doric/widget/flex/FlexLayoutService.h +++ b/doric-Qt/example/doric/widget/flex/FlexLayoutService.h @@ -6,12 +6,14 @@ #include #include +#include "DoricExport.h" + #include "FlexLayoutConfig.h" #include "FlexLayout.h" #include "yoga/Yoga.h" -class FlexLayoutService : public QObject { +class DORIC_EXPORT FlexLayoutService : public QObject { Q_OBJECT private: FlexLayoutConfig *config; diff --git a/doric-Qt/example/example.pro.user b/doric-Qt/example/example.pro.user index 3af03410..e2d144d9 100644 --- a/doric-Qt/example/example.pro.user +++ b/doric-Qt/example/example.pro.user @@ -1,6 +1,6 @@ - + EnvironmentId