Qt World Summit: Register Today!

How to send application in foreground and background in Harmattan programatically??

  • hi, i am currently working on a project where i want to send application to background on button click and bring foreground after some time. could anyone can help?? thanks

    [edit : minor typos in title fixed, Eddy]

  • Hi, maybe a good idea to manage the page stack, pop all the opened pages and see the API that is called when the application goes in background as usual?

    I have not tried this but I see that when I switch the applicaiton from background to foreground the console shows a set of messages regarding what changes. This maybe the starting point.

  • I take a look to the documentation. It seems that you should manage your application status using the QApplication class and its properties. This is the class that grant also access to thte session manager so I think it is possible to activate or deactivate a specific applicaiton.

    Thus in the QApplication class reference I saw that it is possible senEvent() to the application widget and there is one specific event to Activate or Deactivate the application.

  • thanks, it would be helpful information. i will check it out

  • Well, please let me know the results of your tests.

Log in to reply