Integrated: 8191995: Regression: DatePicker must commit on focusLost

Marius Hanl mhanl at openjdk.java.net
Tue Dec 7 19:59:11 UTC 2021


On Wed, 24 Nov 2021 09:09:53 GMT, Marius Hanl <mhanl at openjdk.org> wrote:

> This PR fixes an issue where the `DatePicker` is not committing his text as value when the focus is lost.
> As the ticket also mentions, this is a regression which last worked on JavaFX 8 and got broken by this refactoring: [JDK-8150946](https://bugs.openjdk.java.net/browse/JDK-8150946)
>
> The fix is to provide the same api  to the `DatePicker` which was introduced by [JDK-8150946](https://bugs.openjdk.java.net/browse/JDK-8150946) for `ComboBox` and `Spinner`.
>
> Note: While fixing this I found a possible bug which I tracked here: [JDK-8277756](https://bugs.openjdk.java.net/browse/JDK-8277756)
> -> When creating a `DatePicker` with the second constructor (with `LocalDate` as parameter) two listener won't be added since they are only added at the first constructor (That's also why I added the focusProperty listener in the second constructor).

This pull request has now been integrated.

Changeset: 6fd4ab61
Author:    Marius Hanl <mhanl at openjdk.org>
Committer: Kevin Rushforth <kcr at openjdk.org>
URL:       https://git.openjdk.java.net/jfx/commit/6fd4ab6104ebaa97530ea9182466e6c1e346a4f4
Stats:     133 lines in 2 files changed: 133 ins; 0 del; 0 mod

8191995: Regression: DatePicker must commit on focusLost

Reviewed-by: fastegal, kcr

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

PR: https://git.openjdk.java.net/jfx/pull/679


More information about the openjfx-dev mailing list