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

Java Development

Reply
Developer
Posts: 455
Registered: ‎01-14-2009
My Device: Apple iPhone 3GS 16GB

Check if application is active from the menuitem

hi friends.

 

I have added an application menu item, to ApplicationMenuItemRepository.MENUITEM_SYSTEM so it adds the menuitem to all the screens in the OS. It shows in my application too as expected. Is there anyway, i can check whether the menu item is invoked from inside my application, so I can handle the behaviour of menu item differently? 

Developer
Posts: 16,687
Registered: ‎07-29-2008
My Device: Z10 LE, Z30, Passport
My Carrier: O2 Germany

Re: Check if application is active from the menuitem

use a different entry point, or send a global event.
----------------------------------------------------------
feel free to press the like button on the right side to thank the user that helped you.
please mark posts as solved if you found a solution.
@SimonHain on twitter
Developer
Posts: 455
Registered: ‎01-14-2009
My Device: Apple iPhone 3GS 16GB

Re: Check if application is active from the menuitem

yes, but how do i check if the menu item was invoked from inside my app.
Developer
Posts: 16,687
Registered: ‎07-29-2008
My Device: Z10 LE, Z30, Passport
My Carrier: O2 Germany

Re: Check if application is active from the menuitem

ah ok, i misunderstood your question, i guess. maybe check if your application is the foreground app? maybe the uiapplication object in the menu item is your app.
----------------------------------------------------------
feel free to press the like button on the right side to thank the user that helped you.
please mark posts as solved if you found a solution.
@SimonHain on twitter