I am continually disappointed and frustrated by the way Qt is handled in 
Android.  I have had success with an approach up to now of using a 
QObject-derived platform shim object, which is API consistent with iOS and OSX.

However it seems I'm now encountering a showstopper and I don't know what to 
do. When Android starts your app, Java starts first and any JNI from service 
receivers run in the java thread, without a QApplication. Then sometime later, 
the QtActivity is started and the main() runs. However if no JNI happens, then 
the app starts normally. The two run modes seem incompatible with each other. 

I had always thought that Qt could message across threads so that issue would 
be minimized. However in my latest attempt at using a Connections object, it 
hard aborts when it tries to connect to an object in another thread. 
(https://github.com/richardmg/qtdeclarative/blob/master/src/qml/qml/qqmlnotifier.cpp:111)
 

If I change the JNI to create the QApplication, I have to also create the 
engine, but then when my main() actually runs, I don't know how to hook up the 
smattering of objects in the Android thread with the smattering of objects in 
the Qt application (QML Engine)

I'm so lost.



 
_______________________________________________
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest

Reply via email to