RFR: JDK-8303897 ObservableValue's when binding should only invalidate when strictly needed [v3]
Nir Lisker
nlisker at openjdk.org
Tue Apr 11 01:39:46 UTC 2023
On Mon, 10 Apr 2023 00:14:31 GMT, John Hendrikx <jhendrikx at openjdk.org> wrote:
> Well, I am just following the specification here, but JavaFX itself isn't...
>
> We may need to make a decision here. JavaFX is not consistent itself where it applies `equals` and where it uses reference equality:
Alright, so this is fine for this PR.
As for the equality test, we will need to revise the implementation note (that I wrote) to explain correctly what is used where and consider the changes you proposed. ReactFX uses `equals` internally, and it was very hard to debug why changing to its observables caused a change in the behavior, which is why I'm extra careful about this issue.
My idea was to allow the user to specify their own equality checks when registering a listener, but that requires a lot more thought.
-------------
PR Comment: https://git.openjdk.org/jfx/pull/1056#issuecomment-1502561838
More information about the openjfx-dev
mailing list