bug: http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=7192887 webrev: http://http://cr.openjdk.java.net/~denis/7192887/webrev
UngrabEvent is not sent on some platforms (XToolkit) on window disposal. I have added the code in XWindowPeer.dispose() method.
We do the similar posts on EDT in XWindowPeer but I do not think that extraction the code in a method is needed here.
Thank you, Denis.
