forked from qt-creator/qt-creator
QmlDesigner: Do not try to create objects with invalid version
Change-Id: I15eb8cf006bf8a58eaba4140f062fbf14e417f47 Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io> Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
This commit is contained in:
@@ -633,7 +633,7 @@ QObject *ObjectNodeInstance::createPrimitive(const QString &typeName, int majorN
|
|||||||
|
|
||||||
if (mockHash.contains(typeName))
|
if (mockHash.contains(typeName))
|
||||||
object = QmlPrivateGate::createComponent(mockHash.value(typeName), context);
|
object = QmlPrivateGate::createComponent(mockHash.value(typeName), context);
|
||||||
else
|
else if (majorNumber != -1 && minorNumber != -1)
|
||||||
object = QmlPrivateGate::createPrimitive(polishTypeName, majorNumber, minorNumber, context);
|
object = QmlPrivateGate::createPrimitive(polishTypeName, majorNumber, minorNumber, context);
|
||||||
|
|
||||||
/* Let's try to create the primitive from source, since with incomplete meta info this might be a pure
|
/* Let's try to create the primitive from source, since with incomplete meta info this might be a pure
|
||||||
|
Reference in New Issue
Block a user