JDK-6783619 : showDocument calls result in the new browser window opening behind the current top window.
  • Type: Bug
  • Component: deploy
  • Sub-Component: plugin
  • Affected Version: 6u10,6u14
  • Priority: P3
  • Status: Closed
  • Resolution: Fixed
  • OS: windows,windows_xp
  • CPU: x86
  • Submitted: 2008-12-10
  • Updated: 2011-05-19
  • Resolved: 2011-05-19
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 6 JDK 7
6u17-revFixed 7Fixed
Related Reports
Relates :  
Relates :  
Relates :  
Relates :  
Description
New browser is sent to background instead of foreground where it is expected (should be top of z-order).  This is not the same behavior as seen with earlier versions. 
. 
Tested with expected results using the following JRE versions in Internet Explorer 7 on Windows XP SP3: 

. 
   Sun JRE 1.3.1_21 
   Sun JRE 1.5.0_16 
   Sun JRE 1.6.0_07 
. 
Fails when using JRE/JPI build 1.6.0_10-b33.
(moved comment to the "Comments" section)

Comments
EVALUATION Basically, we need to set focus on the browser window (setting focus on the control window works too) prior to opening a new browser window for displaying a web page. The setting focus on the browser window has an effect of ungrabbing the focus from the applet so that the new browser window can be displayed on top of the existing browser window.
30-05-2009

EVALUATION The best solution found so far is to open the new page in a new browser tab. This can be done by passing 0x0800 as the second argument to the IWebBrowser2->Navigate call. This is also consistent with the behavior with the FF browser.
14-04-2009

EVALUATION To clarify, the problem isn't reproducible if the java console is enabled; it's reproducible with the java console disabled. Investigation shows that with the old plugin, the CAxControl::OnFrameWindowActivate(BOOL fActivate) is always called with fActivate set to FALSE just before the new browser window is created as a result of the showDocument call. With the new plugin, the above method isn't called during showDocument.
27-03-2009

EVALUATION This is no longer reproducible with JRE 6u14 nightly build on XP SP3 / IE7. This could be due to the fix for 6782570 (ClickTagSupport: AppletContext.showDocument should not block the new requested window) in 6u12.
29-01-2009