Hi,

I do the following for quick oauth2 background html handling:

<meta-data android:name="android.app.background_running" android:value="true"/>

inside the Qt activity tag of the AndroiManifest.xml


I wish it was easier to specify a single network activity that can continue 
into the background or at least a network intent that can wake the application 
up (could handle the message an/or bring application up front again).


I think you will need to create a service to have a full fledge UDP listener 
that continue even after the application screen goes off. That service will 
need to communicate with your application through intent I think. The service 
could try to wake your application. Not a specialist about this but this might 
help, good luck and let us known how you did solve it, I'm curious about all 
this, this still a pain to make those work properly.

________________________________
From: Interest <interest-bounces+godboutj=amotus...@qt-project.org> on behalf 
of Denis Shienkov <denis.shien...@gmail.com>
Sent: Thursday, February 15, 2018 9:25:38 AM
To: interest@qt-project.org
Subject: [Interest] How to make the QML gui be never stopped on Android


Hi all,

I use QML and Qt 5.9.3 on my Android application.

I achieved some tricks that my application continued to
work when the smartphone goes to sleep or when the user
presses the 'power' button, i.e. seems, that an
application running in background mode.

I do not use an Android service here (because I dont
know how to do it, also I'm not sure that this will help).

So, when the application goes to background mode,
I see that it continues to work, because I see that
my UDP "keep-alive" messages are sends and receives.

But, A MAIN problem is that a QML GUI is stopped then...
i.e. does not updates.

I need to do GUI grabbing in a real time and send it
to UDP in any case.

Is it possible to make a GUI work forewer?

BR,
Denis

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

Reply via email to