aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml/qml/qqmlengine.cpp
diff options
context:
space:
mode:
authorMarco Bubke <marco.bubke@digia.com>2012-11-22 11:28:57 +0100
committerThe Qt Project <gerrit-noreply@qt-project.org>2012-11-22 12:34:41 +0100
commit8fc95e65e77328c995ef4a3a633a95c86f5e0bdf (patch)
treec36f38de6625c04b1ab51e08f8f9e7e78dc1fa1f /src/qml/qml/qqmlengine.cpp
parentc2a6e7276dfce6142202ee9db4aaaf15a53cb530 (diff)
Add designer support for animations and componentComplete
In the designer animations confuse users, if you change a state or move a item around. Also component complete is called later by the designer. The call in the VME is to early. Change-Id: I49aa04edbc49fb44ddb7b52062307982865efd7e Reviewed-by: Thomas Hartmann <Thomas.Hartmann@digia.com>
Diffstat (limited to 'src/qml/qml/qqmlengine.cpp')
-rw-r--r--src/qml/qml/qqmlengine.cpp11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/qml/qml/qqmlengine.cpp b/src/qml/qml/qqmlengine.cpp
index f0bf6e4e20..1376ad7106 100644
--- a/src/qml/qml/qqmlengine.cpp
+++ b/src/qml/qml/qqmlengine.cpp
@@ -165,6 +165,7 @@ void qmlRegisterBaseTypes(const char *uri, int versionMajor, int versionMinor)
*/
bool QQmlEnginePrivate::qml_debugging_enabled = false;
+bool QQmlEnginePrivate::s_designerMode = false;
// these types are part of the QML language
void QQmlEnginePrivate::registerBaseTypes(const char *uri, int versionMajor, int versionMinor)
@@ -192,6 +193,16 @@ void QQmlEnginePrivate::defineQtQuick2Module()
qmlRegisterUncreatableType<QQmlLocale>("QtQuick", 2, 0, "Locale", QQmlEngine::tr("Locale cannot be instantiated. Use Qt.locale()"));
}
+bool QQmlEnginePrivate::designerMode()
+{
+ return s_designerMode;
+}
+
+void QQmlEnginePrivate::activateDesignerMode()
+{
+ s_designerMode = true;
+}
+
/*!
\class QQmlImageProviderBase