Important: Please read the Qt Code of Conduct -

Qt Android application running in background

  • Hello!

    I'm trying to make a clock alarm for Android. I've encountered the following problem: if the application is turned on, and the user set the time for alarm and press the "back" button on the phone, the processes is killed. How can I handle this situation? I want the application to continue running in background?

  • @SebiSebi2 For this use case I guess it would be best to intercept the back button event in native Java Android code and put the activity in the background instead.

    Alex from V-Play

  • And how can I put the activity in the background? If I overwrite closeEvent(QCloseEvent *) what should I write inside in order to make the application run in the background?

Log in to reply