Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Native Development

Reply
Developer
Posts: 1,554
Registered: ‎07-14-2008
My Device: Z10
My Carrier: Fido

How to get currently active window?

In my app i can reference my app's window using the following:

 

Window *cascadesWindow = Application::instance()->mainWindow();

 

If I put the app in the background and then run another application how do I get the "currently running application's window"?

 

 

 

Developer
Posts: 825
Registered: ‎10-16-2012
My Device: Red Z10
My Carrier: Rogers

Re: How to get currently active window?

if you save a variable of which window was running at the time your application was thumbnailed etc, that would let you know which window to open back up when the app is brought to the foreground, or even opened back up again.

Developer
Posts: 1,554
Registered: ‎07-14-2008
My Device: Z10
My Carrier: Fido

Re: How to get currently active window?

thanks but i don't want my own "app" window.  I want the current active app's window.

 

say if i put my app in the background and then run calendar app i want the calendar's window.