Community
Participate
Working Groups
There are 2 options of creating a new internal browser: using a new window every time or opening the URL in the same window, using the same browser ID. In the class "DefaultBrowserSupport" there is a function called "getExistingWebBrowser". The function checks if the given ID exists in the hash "browserIdMap". If it doesn't it creates a new browser and it enters the ID in the hash. If the id exists it should open the URL in the same window, but it doesn't happen. The reason is the following: Every time a URL is sent to the browser, it is added to the browser history in the function "setURL" (there is a call to 'addToHistory')in class "BrowserViewer". In 'addToHistory' there is a call to WebBrowserPreference.setInternalWebBrowserHistory. This call triggers a call to "update" in the observer attached to DefaultBrowserSupport. (in the constructor). In the update the hash "browserIdMap" is cleared!!!! It means that it is impossible to use the "Existing browser" feature, since the browserIdMap is cleared on every call. There is a TODO remark in the 'update' function saying: "// TODO I am not sure what we should do here // The preferences have changed so maybe we should // close the opened browsers in addition to clearing // the table " browserIdMap.clear(); is clearly NOT what needs to be done here, at least not in every case.
*** Bug 146578 has been marked as a duplicate of this bug. ***
This looks like a duplicate of bug 132889 which is now fixed. Moving to UA to confirm.
Correct. *** This bug has been marked as a duplicate of 132889 ***
closed