[jdk20] RFR: 8301989: new javax.swing.text.DefaultCaret().setBlinkRate(N) results in NPE [v2]

Harshitha Onkar honkar at openjdk.org
Wed Feb 8 00:25:44 UTC 2023


On Tue, 7 Feb 2023 23:23:24 GMT, Alexander Zuev <kizune at openjdk.org> wrote:

>> Check if the component is associated with the caret before calling methods from it. Added test case that will make sure that will not happen again.
>
> Alexander Zuev has updated the pull request incrementally with one additional commit since the last revision:
> 
>   Fixe copyright year.

The patch works as expected. NPE problem is resolved. Additionally checked the fix by adding DefaultCaret to component (JTextField) in enabled and disabled states, it works as expected - Blinking caret when enabled and no caret when disabled.

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

Marked as reviewed by honkar (Committer).

PR: https://git.openjdk.org/jdk20/pull/122



More information about the client-libs-dev mailing list