diff options
author | Bart Vanhauwaert <bart.vanhauwaert@grafitroniks.fr> | 2016-11-22 10:38:53 +0100 |
---|---|---|
committer | Bart Vanhauwaert <bart.vanhauwaert@grafitroniks.fr> | 2016-11-23 11:40:19 +0100 |
commit | b75203281761e2f73d67c9d8c1474668c90ea24e (patch) | |
tree | 60b2d7faf07933130e982cc0707039a9acb71d62 | |
parent | Exclude QList<QModelIndex> from Q_DECLARE_METATYPE (diff) | |
download | qtscriptgenerator-b75203281761e2f73d67c9d8c1474668c90ea24e.tar.xz qtscriptgenerator-b75203281761e2f73d67c9d8c1474668c90ea24e.zip |
Remove QMetaFunctionHelper::Create wrapper
Mimick change in qtbase.git since the ::Create wrapper can be
simulated with the more generic ::Construct one. See commit
3d575d4845926bd141ff0c14e57427bba79644d0 in qtbase.git for more
discussion
-rw-r--r-- | qtbindings/qtscript_core/include/__package_shared.h | 8 | ||||
-rw-r--r-- | qtbindings/qtscript_gui/include/__package_shared.h | 24 |
2 files changed, 0 insertions, 32 deletions
diff --git a/qtbindings/qtscript_core/include/__package_shared.h b/qtbindings/qtscript_core/include/__package_shared.h index 2b5444a..5db4253 100644 --- a/qtbindings/qtscript_core/include/__package_shared.h +++ b/qtbindings/qtscript_core/include/__package_shared.h @@ -15,14 +15,6 @@ Q_DECLARE_METATYPE(QEvent) namespace QtMetaTypePrivate { template <> -inline void *QMetaTypeFunctionHelper<QEvent, true>::Create(const void *t) -{ - if (t) - return new QEvent(*static_cast<const QEvent*>(t)); - return new QEvent(QEvent::None); -}; - -template <> inline void *QMetaTypeFunctionHelper<QEvent, true>::Construct(void *where, const void *t) { if (t) diff --git a/qtbindings/qtscript_gui/include/__package_shared.h b/qtbindings/qtscript_gui/include/__package_shared.h index 98c6239..f31928d 100644 --- a/qtbindings/qtscript_gui/include/__package_shared.h +++ b/qtbindings/qtscript_gui/include/__package_shared.h @@ -16,14 +16,6 @@ Q_DECLARE_METATYPE(QFontMetricsF) namespace QtMetaTypePrivate { template <> -inline void *QMetaTypeFunctionHelper<QFontInfo, true>::Create(const void *t) -{ - if (t) - return new QFontInfo(*static_cast<const QFontInfo*>(t)); - return new QFontInfo(QFont()); -} - -template <> inline void *QMetaTypeFunctionHelper<QFontInfo, true>::Construct(void *where, const void *t) { if (t) @@ -36,14 +28,6 @@ inline void *QMetaTypeFunctionHelper<QFontInfo, true>::Construct(void *where, co template <> -inline void *QMetaTypeFunctionHelper<QFontMetrics, true>::Create(const void *t) -{ - if (t) - return new QFontMetrics(*static_cast<const QFontMetrics*>(t)); - return new QFontMetrics(QFont()); -} - -template <> inline void *QMetaTypeFunctionHelper<QFontMetrics, true>::Construct(void *where, const void *t) { if (t) @@ -55,14 +39,6 @@ inline void *QMetaTypeFunctionHelper<QFontMetrics, true>::Construct(void *where, template <> -inline void *QMetaTypeFunctionHelper<QFontMetricsF, true>::Create(const void *t) -{ - if (t) - return new QFontMetricsF(*static_cast<const QFontMetricsF*>(t)); - return new QFontMetricsF(QFont()); -} - -template <> inline void *QMetaTypeFunctionHelper<QFontMetricsF, true>::Construct(void *where, const void *t) { if (t) |