create the Layout attached object in init()

always create it and create it immediately.
this way it's possible for other c++ users to find it
This commit is contained in:
Marco Martin 2014-08-27 13:37:56 +02:00
parent 49bb894a21
commit 6a190670ba

View File

@ -89,8 +89,6 @@ void AppletQuickItemPrivate::connectLayoutAttached(QObject *item)
propagateSizeHint("fillWidth");
propagateSizeHint("fillHeight");
//HACK: check the Layout properties we wrote
QQmlProperty p(q, "Layout.minimumWidth", QtQml::qmlContext(qmlObject->rootObject()));
QObject *ownLayout = 0;
@ -500,6 +498,9 @@ void AppletQuickItem::init()
d->compactRepresentationExpander->loadUrl(QUrl::fromLocalFile(d->coronaPackage.filePath("compactapplet")));
}
//HACK: check the Layout properties we wrote
QQmlProperty p(this, "Layout.minimumWidth", QtQml::qmlContext(d->qmlObject->rootObject()));
d->compactRepresentationCheckTimer.start();
}