immediately parent objects
don't let representations without parents, avoid possible leaks and fix cases in which the applet relies on ht eparent hyerarchy, such as ColorContext
This commit is contained in:
parent
eb4edb0e9e
commit
c60ca1b6a0
@ -187,7 +187,10 @@ QQuickItem *AppletQuickItemPrivate::createCompactRepresentationItem()
|
||||
return compactRepresentationItem;
|
||||
}
|
||||
|
||||
compactRepresentationItem = qobject_cast<QQuickItem*>(qmlObject->createObjectFromComponent(compactRepresentation, QtQml::qmlContext(qmlObject->rootObject())));
|
||||
QVariantHash initialProperties;
|
||||
initialProperties["parent"] = QVariant::fromValue(q);
|
||||
|
||||
compactRepresentationItem = qobject_cast<QQuickItem*>(qmlObject->createObjectFromComponent(compactRepresentation, QtQml::qmlContext(qmlObject->rootObject()), initialProperties));
|
||||
|
||||
emit q->compactRepresentationItemChanged(compactRepresentationItem);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user