aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml/qml/qqmlobjectcreator_p.h
diff options
context:
space:
mode:
authorSimon Hausmann <simon.hausmann@digia.com>2014-03-03 15:01:04 +0100
committerThe Qt Project <gerrit-noreply@qt-project.org>2014-03-03 17:39:15 +0100
commit5a06bc73822576cb9ffceb243f43f6b28fd6b4dc (patch)
tree6cc922f3a2fd0fd6be4d3e6273d0f603efd158e0 /src/qml/qml/qqmlobjectcreator_p.h
parent307bdba9c3c068ac7e7ded291bbd1b34054af42b (diff)
Work around MSVC having issues with nested classes and templates
Move SharedState into its own top-level structure. Change-Id: I0b6baeade57ff342df23672808d77933fa6ad26d Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Diffstat (limited to 'src/qml/qml/qqmlobjectcreator_p.h')
-rw-r--r--src/qml/qml/qqmlobjectcreator_p.h24
1 files changed, 12 insertions, 12 deletions
diff --git a/src/qml/qml/qqmlobjectcreator_p.h b/src/qml/qml/qqmlobjectcreator_p.h
index d72b9ec065..5b7ee039c4 100644
--- a/src/qml/qml/qqmlobjectcreator_p.h
+++ b/src/qml/qml/qqmlobjectcreator_p.h
@@ -54,10 +54,19 @@ class QQmlAbstractBinding;
struct QQmlTypeCompiler;
class QQmlInstantiationInterrupt;
+struct QQmlObjectCreatorSharedState
+{
+ QQmlContextData *rootContext;
+ QQmlContextData *creationContext;
+ QFiniteStack<QQmlAbstractBinding*> allCreatedBindings;
+ QFiniteStack<QQmlParserStatus*> allParserStatusCallbacks;
+ QQmlComponentAttached *componentAttached;
+ QList<QQmlEnginePrivate::FinalizeCallback> finalizeCallbacks;
+};
+
class QQmlObjectCreator
{
Q_DECLARE_TR_FUNCTIONS(QQmlObjectCreator)
- struct SharedState;
public:
QQmlObjectCreator(QQmlContextData *parentContext, QQmlCompiledData *compiledData, QQmlContextData *creationContext);
~QQmlObjectCreator();
@@ -74,7 +83,7 @@ public:
QQmlContextData *parentContextData() const { return parentContext; }
private:
- QQmlObjectCreator(QQmlContextData *contextData, QQmlCompiledData *compiledData, SharedState *inheritedSharedState);
+ QQmlObjectCreator(QQmlContextData *contextData, QQmlCompiledData *compiledData, QQmlObjectCreatorSharedState *inheritedSharedState);
void init(QQmlContextData *parentContext);
@@ -92,15 +101,6 @@ private:
QString stringAt(int idx) const { return qmlUnit->header.stringAt(idx); }
void recordError(const QV4::CompiledData::Location &location, const QString &description);
- struct SharedState {
- QQmlContextData *rootContext;
- QQmlContextData *creationContext;
- QFiniteStack<QQmlAbstractBinding*> allCreatedBindings;
- QFiniteStack<QQmlParserStatus*> allParserStatusCallbacks;
- QQmlComponentAttached *componentAttached;
- QList<QQmlEnginePrivate::FinalizeCallback> finalizeCallbacks;
- };
-
QQmlEngine *engine;
QQmlCompiledData *compiledData;
const QV4::CompiledData::QmlUnit *qmlUnit;
@@ -110,7 +110,7 @@ private:
const QVector<QQmlPropertyCache *> &propertyCaches;
const QVector<QByteArray> &vmeMetaObjectData;
QHash<int, int> objectIndexToId;
- QFlagPointer<SharedState> sharedState;
+ QFlagPointer<QQmlObjectCreatorSharedState> sharedState;
QObject *_qobject;
QObject *_scopeObject;