JDK-6272277 : PIT. Frame does not open behind a modal dialog
  • Type: Bug
  • Component: client-libs
  • Sub-Component: java.awt
  • Affected Version: 6
  • Priority: P2
  • Status: Closed
  • Resolution: Fixed
  • OS: generic,windows_xp
  • CPU: generic,x86
  • Submitted: 2005-05-18
  • Updated: 2012-10-01
  • Resolved: 2005-07-23
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
6 b45Fixed
Related Reports
Duplicate :  
Relates :  
Relates :  
Description
This occurs in AWT PIT build for mustang b38

java version "1.6.0-awt.pit-int-jcg-linux-02"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.6.0-awt.pit-int-jcg-linux-02-dm97671_11_may_2005_09_09-b00)
Java HotSpot(TM) Client VM (build 1.6.0-ea-b35, mixed mode)

I've a modal dialog opened up which blocks a Frame. From a different thread, I'm opening a Frame. The Frame is not displayed behind the Modal dialog on Windows. This is the same behavior explained in 4607481. The fix for the bug works on Solaris/Linux. On Windows, the Frame appears on top of the modal dialog. But when the Frame title bar is clicked, it goes behind the dialog.

On Solaris/Linux, the newly appearing Frame do not get minimized if the Dialog and the blocked Frames are minimized. The newly appearing Frames appear in blocked state. When I click anywhere on the title bar, it gets minimized.

To reproduce:
Run the attached testcase. It opens a Frame blocked by a modal dialog. A new frame appears every 10 seconds. Check where the Frame appears on a windows system. Minimize the Dialog/Frame by clicking the minimize button on the Frame title bar on Solaris / Linux. Check where the new Frames appear.
###@###.### 2005-05-18 09:27:00 GMT

Comments
SUGGESTED FIX --- awt_Window.cpp Wed May 18 17:29:39 2005 *************** *** 1566,1571 **** --- 1566,1572 ---- if (::IsWindow(windowHWnd) && ::IsWindow(blockerHWnd)) { AwtWindow::SetModalBlocker(windowHWnd, blockerHWnd); + ::SetForegroundWindow(blockerHWnd); } ret: ###@###.### 2005-05-18 13:35:59 GMT
18-05-2005

EVALUATION We should check if a frame is blocked when it is opened and, if it is, bring the modal blocker dialog to front. Currently, the dialog is brought to front only on mouse clicks and activations. ###@###.### 2005-05-18 13:35:59 GMT The first version of the fix was not complete: modal blocker dialog was just made a foreground window, but was not brought to top. Also, the same check is added to one more similiar place. ###@###.### 2005-07-06 09:03:30 GMT
18-05-2005