Hide Qt app from task list



  • Environment: Qt for S60
    I want my Qt application hide and show as needed. When I try to hide it by calling MyDialog.hide(), it has 2 problems:
    1, It is available in the task list popup window.
    2, After I call MyDialog.hide(), the softkey still keeps not changed. When I press softkey 'Exit', the app will exit. Seems it still 'visible'.
    How to hide it completely? Thanks very much for any reply.



  • I think you should use Symbian API to do it. Maybe someone more familiar with native Symbian programming can say how to do it?



  • I think the closest you can come to this in Qt API is using QWidget::lower() on the top level window. That will send the underlying window to the back of the window tree and should also do the same for your window group. Hide simply hides the currently active window without changing the Z-order of anything which is why your softkeys are still visible (they are not really tied to the window).

    As for removing your application from the task list popup (officially called Fast Swap Window in Symbian), there is no API in Qt to do this currently so you have to do it using native Symbian code. Something like the following would probably work:

    @
    CCoeEnv *env = CCoeEnv::Static();
    CApaWindowGroupName *wgName = CApaWindowGroupName::NewLC(env->WsSession());
    wgName->SetHidden(ETrue);
    @

    You can probably find more examples on Forum Nokia.


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.