summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLillian Angel <langel@redhat.com>2005-11-11 16:12:37 +0000
committerLillian Angel <langel@redhat.com>2005-11-11 16:12:37 +0000
commit8151e23d14cba32719c44d65975465de6c352191 (patch)
treea77478aca791df98f1cffe8f55cc71345bd88cae
parentb33481c64e92a140fd986aef09b28fe638c9aaf1 (diff)
downloadclasspath-8151e23d14cba32719c44d65975465de6c352191.tar.gz
2005-11-11 Lillian Angel <langel@redhat.com>
* java/awt/Container.java (LightweightDispatcher.acquireComponentForMouseEvent): If the event is not being dispatched, the pressCount should be reset.
-rw-r--r--ChangeLog6
-rw-r--r--java/awt/Container.java7
2 files changed, 11 insertions, 2 deletions
diff --git a/ChangeLog b/ChangeLog
index a3d467e6a..1788a8568 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2005-11-11 Lillian Angel <langel@redhat.com>
+
+ * java/awt/Container.java
+ (LightweightDispatcher.acquireComponentForMouseEvent): If the
+ event is not being dispatched, the pressCount should be reset.
+
2005-11-11 Mark Wielaard <mark@klomp.org>
* javax/swing/text/FieldView.java (getPreferredSpan): Chain
diff --git a/java/awt/Container.java b/java/awt/Container.java
index 91d63c653..4676895bf 100644
--- a/java/awt/Container.java
+++ b/java/awt/Container.java
@@ -2166,7 +2166,10 @@ class LightweightDispatcher implements Serializable
// Don't dispatch CLICKED events whose target is not the same as the
// target for the original PRESSED event.
if (candidate != pressedComponent)
- mouseEventTarget = null;
+ {
+ mouseEventTarget = null;
+ pressCount = 0;
+ }
else if (pressCount == 0)
pressedComponent = null;
}
@@ -2204,7 +2207,7 @@ class LightweightDispatcher implements Serializable
pressedComponent = null;
break;
}
-
+
MouseEvent newEvt =
AWTUtilities.convertMouseEvent(nativeContainer, me,
mouseEventTarget);