<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body text="#000000" bgcolor="#FFFFFF">
use lastWindowClosed signal instead of destroyed<br>
and<br>
int retval = app->exec();<br>
delete x;<br>
delete y;<br>
return retval;<br>
<br>
<div class="moz-cite-prefix">On 22.12.2013 21:22, Mikael Hermansson
wrote:<br>
</div>
<blockquote cite="mid:2440474.Qx0iWRnotg@thinkpad-x230" type="cite">
<pre wrap="">Cant figure out what I am doing wrong but it seems mainloop does not shutdown when
using QQuickView like below.
And I can't figure out what signal I should conect to? Or more exact what signal is sent from
sailfish when app is closed?
AFAIK SailfishApp is just a subclass of QQuickView but there is no public API what signals it
implements/overrides?
[code]
QGuiApplication *app = SailfishApp::application(argc, argv);
UDPManager *udp = new UDPManager();
QQuickView *view = SailfishApp::createView();
/* FIXME: THIS DOES NOT WORK */
QObject::connect(view, SIGNAL(destroyed()), view, SLOT(QGuiApplication::quit()));
view->rootContext()->setContextProperty("version", QString(VERSION));
view->rootContext()->setContextProperty("udp", udp);
view->setSource(QString("/usr/share/harbour-push2sail/qml/push2sail.qml"));
view->showFullScreen();
app->exec();
delete app;
delete udp;
[/code]
</pre>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<br>
<pre wrap="">_______________________________________________
SailfishOS.org Devel mailing list</pre>
</blockquote>
<br>
</body>
</html>