Commit e4b49acf authored by Alessandro Portale's avatar Alessandro Portale
Browse files

Let Qml scene define the window size on Desktop

And also prevent a 0-size if the Qml document does not specify
width/height.
parent 7bcbf65a
......@@ -16,7 +16,6 @@ int main(int argc, char *argv[])
#elif defined(Q_WS_MAEMO_5) || defined(Q_WS_MAEMO_6)
qmlApp.showMaximized();
#else
qmlApp.setGeometry(QRect(100, 100, 360, 640));
qmlApp.show();
#endif
return app.exec();
......
......@@ -33,6 +33,7 @@ QmlApplicationView::QmlApplicationView(const QString &mainQmlFile, QWidget *pare
setSource(QUrl(m_d->mainQmlFile));
connect(engine(), SIGNAL(quit()), SLOT(close()));
setResizeMode(QDeclarativeView::SizeRootObjectToView);
setMinimumSize(10, 10); // Prevent size of 0 if Qml document does not specify width/height
}
QmlApplicationView::~QmlApplicationView()
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment