7192887: java/awt/Window/Grab/GrabTest.java still failed (fix failed for CR 7149068)
Reviewed-by: ant, serb
--- a/jdk/src/solaris/classes/sun/awt/X11/XWindowPeer.java Wed Aug 29 19:53:35 2012 +0400
+++ b/jdk/src/solaris/classes/sun/awt/X11/XWindowPeer.java Thu Aug 30 01:17:24 2012 +0400
@@ -1165,15 +1165,25 @@
}
public void dispose() {
+ if (isGrabbed()) {
+ if (grabLog.isLoggable(PlatformLogger.FINE)) {
+ grabLog.fine("Generating UngrabEvent on {0} because of the window disposal", this);
+ }
+ postEventToEventQueue(new sun.awt.UngrabEvent(getEventSource()));
+ }
+
SunToolkit.awtLock();
+
try {
windows.remove(this);
} finally {
SunToolkit.awtUnlock();
}
+
if (warningWindow != null) {
warningWindow.destroy();
}
+
removeRootPropertyEventDispatcher();
mustControlStackPosition = false;
super.dispose();
@@ -1191,6 +1201,7 @@
}
}
}
+
boolean isResizable() {
return winAttr.isResizable;
}