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
Highlighted
New Contributor
Posts: 3
Registered: ‎04-14-2014
My Device: 9790
My Carrier: Plus (Poland)

Menu item in Browser

Hi,

 

I was wondering, if I could place an menu item in native browser, which would appear after long clicking link. I noticed, that after installing Opera Mini there was an "Open in Opera Mini" option on link. I wanted to have my own menu item, so browser could send URL of link to my app.

 

Thanks in advance

Michal

Developer
Posts: 19,636
Registered: ‎07-14-2008
My Device: Not Specified

Re: Menu item in Browser

Have a look at ApplicationMenuItem.  You add these using ApplicationMenuItemRepository, and I think you will use MENUITEM_BROWSER to restrict the menu to just the Browser.  I am not sure how you can find out the URL you want, never looked at that.  You should also be aware that this menu items runs nder the control (context) of the Browser, so you might want to use something like a GlobalEvent to get control back into your own application context. 

New Contributor
Posts: 3
Registered: ‎04-14-2014
My Device: 9790
My Carrier: Plus (Poland)

Re: Menu item in Browser

Hi, thanks for reply. I can now add MenuItem to Browser, but I still can't make it show only when user clicks on link.

 

Michał

Developer
Posts: 19,636
Registered: ‎07-14-2008
My Device: Not Specified

Re: Menu item in Browser

Sorry, I missed that part of the question.  I am not aware of a way of doing that.