7110590: DnDMerlinQLTestsuite_DnDJTextArea test fails with an java.awt.dnd.InvalidDnDOperationException

Reviewed-by: art
This commit is contained in:
Denis Fokin 2012-01-17 19:09:32 +04:00
parent e20614ed03
commit 36b3d034d2

View File

@ -802,9 +802,12 @@ public class AWTKeyStroke implements Serializable {
*/ */
protected Object readResolve() throws java.io.ObjectStreamException { protected Object readResolve() throws java.io.ObjectStreamException {
synchronized (AWTKeyStroke.class) { synchronized (AWTKeyStroke.class) {
if (getClass().equals(getAWTKeyStrokeClass())) {
return getCachedStroke(keyChar, keyCode, modifiers, onKeyRelease); return getCachedStroke(keyChar, keyCode, modifiers, onKeyRelease);
} }
} }
return this;
}
private static int mapOldModifiers(int modifiers) { private static int mapOldModifiers(int modifiers) {
if ((modifiers & InputEvent.SHIFT_MASK) != 0) { if ((modifiers & InputEvent.SHIFT_MASK) != 0) {