From 7f1a13ebbb28db7d2a2694967185c4b80dd31f0d Mon Sep 17 00:00:00 2001 From: Thomas Hartmann Date: Fri, 20 Nov 2015 13:23:02 +0100 Subject: Fixing compilation with -no-rtti DesignerSupport should not keep users from compiling with -no-rtti. Next step is to move DesignerSupport into a library and only build it on desktop platforms. Task-number: QTBUG-49154 Change-Id: Ie0037f3371c24da56f34f27b1f39e8c318e41451 Reviewed-by: Simon Hausmann --- src/quick/designer/qquickdesignercustomobjectdata.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src') diff --git a/src/quick/designer/qquickdesignercustomobjectdata.cpp b/src/quick/designer/qquickdesignercustomobjectdata.cpp index 1666ffb0a5..7f074d8341 100644 --- a/src/quick/designer/qquickdesignercustomobjectdata.cpp +++ b/src/quick/designer/qquickdesignercustomobjectdata.cpp @@ -181,7 +181,11 @@ void QQuickDesignerCustomObjectData::doResetProperty(QQmlContext *context, const if (hasValidResetBinding(propertyName)) { QQmlAbstractBinding *binding = getResetBinding(propertyName); +#if defined(QT_NO_DYNAMIC_CAST) + QQmlBinding *qmlBinding = static_cast(binding); +#else QQmlBinding *qmlBinding = dynamic_cast(binding); +#endif if (qmlBinding) qmlBinding->setTarget(property); QQmlPropertyPrivate::setBinding(binding, QQmlPropertyPrivate::None, QQmlPropertyPrivate::DontRemoveBinding); -- cgit v1.2.3