<AWT Dev> [10] Review request for 8177414: Missing key events on Mac Os

Sergey Bylokhov Sergey.Bylokhov at oracle.com
Fri Aug 4 00:07:02 UTC 2017

Looks fine.

On 02.08.2017 7:26, Dmitry Markov wrote:
> Hello,
> Could you review a fix for jdk10, please?
>     bug: https://bugs.openjdk.java.net/browse/JDK-8177414
>     webrev: http://cr.openjdk.java.net/~dmarkov/8177414/webrev.00/
> Problem description:
> On OSX KEY_TYPED and KEY_PRESSED events might be lost if the input method such as ‘British’, ‘US International’ is set. That is caused by the current implementation of keyDown() method (see AWTView.m) which is responsible for transmitting native KEY_PRESSED events to java layer. If the flag willBeHandledByComplexInputMethod is set, the method stops sending the events to the java layer. However in some cases we may not have InputMethod object and KEY_PRESSED events will be incorrectly dropped.
> Fix:
> In keyDown() we have to check InputMethod object and drop key events only when non-null InputMethod is present.
> Testing:
> I ran corresponding JCK and regression tests and did not observe any new failures.
> Thanks,
> Dmitry

Best regards, Sergey.

More information about the awt-dev mailing list