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
New Developer
Posts: 14
Registered: ‎06-08-2011
My Device: BlackBerry Torch
My Carrier: N/A
Accepted Solution

BrowserField loads pages initially, but fails after first load

My app is displaying pages inside of a BrowserField. The app is mostly a wrapper for a website, so lots of navigation is expected to occur inside the Browser. When the page first loads, it loads the website fine, but if you click any of the links, it never loads the page. 

Stranger still, the whole app works fine in the Simulator, the first page and all the other pages load fine. You can click any link, and it will load.

I have a BrowserFieldListener, and a BrowserFieldController to detect when a page is loaded (To end the loading animation and show the Browser) and when a Link is clicked (To start the loading animation and hide the Browser). Breakpoints in both of those functions (handleNavigationRequest and documentLoaded) show that the first time, both are being reached, but when a link is clicked, handleNavigationRequest is run, but never documentLoaded. 

 

Does anyone have any insight on this? It's been driving me crazy. I don't understand why it works in the Simulator, but not an actual device.

-Thanks

New Developer
Posts: 14
Registered: ‎06-08-2011
My Device: BlackBerry Torch
My Carrier: N/A

Re: BrowserField loads pages initially, but fails after first load

Solved my own problem. A BrowserField won't do anything if it's not attatched to a Manager. Why it loads the original page without being on a manager is a mystery, but keeping it on the page makes it load just fine.

 

Who knows.