<AWT Dev> RFR: 8253681: closed java/awt/dnd/MouseEventAfterStartDragTest/MouseEventAfterStartDragTest.html test failed

Sergey Bylokhov serb at openjdk.java.net
Thu Oct 8 06:49:43 UTC 2020


On Wed, 7 Oct 2020 07:13:53 GMT, Aleksey Shipilev <shade at openjdk.org> wrote:

> The iron-clad fix would be to synchronously insert something like `DiscardMouseEvent` on the beginning of event queue,
> and `AcceptMouseEvent` at the end of it, and let the `EventQueue` processor thread manage the flag -- so that
> `EventQueue` serializes everything, like it is designed to?

Unfortunately, it is not possible to store this flag in EventQueue nor EventDispatchThread and maintain it using
upcoming events, the JVM may run a few applications in parallel so it may have more than one
EventQueue/EventDispatchThread and this code was written to discard all events in all apps while one of them start DnD.

The code could be changed though when the support of multiple EventQueue/EventDispatchThread will be finally dropped.

-------------

PR: https://git.openjdk.java.net/jdk/pull/491


More information about the awt-dev mailing list