How to let application know whether the user's focus is in Home Screen
After letting an application run background, I want the application always to catch an event to notify whether the user's focus is in Home Screen or not. (For instance, Home Screen is shown when user push the home button). Any solutions or hints are appreciated!
Re: How to let application know whether the user's focus is in Home Screen
RWindowTreeNode::EnableFocusChangeEvents, then RWsSession will deliver these events.
Re: How to let application know whether the user's focus is in Home Screen
[QUOTE=wizard_hu_;773146]RWindowTreeNode::EnableFocusChangeEvents, then RWsSession will deliver these events.[/QUOTE]
As the application sometimes runs background, sometimes runs foreground. Where to receive these events to trigger what I want to do in general. For instance, using HandleWsEventL(const TWsEvent& aEvent, CCoeControl* aDestination) only can catch the event when application is focused when running foreground. How to receive "WS" events when application is sent to backgorund. Thanks.
Re: How to let application know whether the user's focus is in Home Screen
[QUOTE=sikamedia;773433]For instance, using HandleWsEventL(const TWsEvent& aEvent, CCoeControl* aDestination) only can catch the event when application is focused when running foreground.[/QUOTE]That is not true.
Re: How to let application know whether the user's focus is in Home Screen
This example gives you the foreground application UID every time it changes. You can use it to detect when the home screen is on top:
[URL="http://wiki.forum.nokia.com/index.php/Capturing_foreground_events"]http://wiki.forum.nokia.com/index.php/Capturing_foreground_events[/URL]
Re: How to let application know whether the user's focus is in Home Screen
Thanks! my problem is solved:)