fix Escape in dialogs, etc

This commit is contained in:
Konstantin Bulenkov
2012-02-05 11:48:37 +01:00
parent 9765fabcad
commit 78059e5408
@@ -255,7 +255,7 @@ public abstract class MouseDragHelper implements MouseListener, MouseMotionListe
@Override
public boolean dispatchKeyEvent(KeyEvent e) {
if (e.getKeyCode() == KeyEvent.VK_ESCAPE && e.getID() == KeyEvent.KEY_PRESSED) {
if (e.getKeyCode() == KeyEvent.VK_ESCAPE && e.getID() == KeyEvent.KEY_PRESSED && myDraggingNow) {
myCancelled = true;
if (myDetachingMode) {
processDragOutCancel();