RFR: 8258777: SkinBase: add api to un-/register invalidation-/listChange listeners [v8]

Nir Lisker nlisker at openjdk.java.net
Mon Apr 12 14:03:35 UTC 2021


On Mon, 12 Apr 2021 10:39:07 GMT, Jeanette Winzenburg <fastegal at openjdk.org> wrote:

>> Changes in Lambda..Handler:
>> - added api and implemenation to support invalidation and listChange listeners in the same way as changeListeners
>> - added java doc 
>> - added tests
>> 
>> Changes in SkinBase
>> - added api (and implementation delegating to the handler)
>> - copied java doc from the change listener un/register methods 
>> - added tests to verify that the new (and old) api is indeed delegating to the handler
>> 
>> Note that the null handling is slightly extended: all methods now can handle both null consumers (as before) and null observables (new) - this allows simplified code on rewiring "path" properties (see reference example in the issue)
>
> Jeanette Winzenburg has updated the pull request incrementally with one additional commit since the last revision:
> 
>   replaced param name in changeListener methods

I looked at all the new public docs and they look good (I left one minor comment). I didn't review anything else.

modules/javafx.controls/src/main/java/javafx/scene/control/SkinBase.java line 286:

> 284:      * Registers an operation to perform when the given {@code observableList} sends a list change event.
> 285:      * Does nothing if either {@code observableList} or {@code operation} are {@code null}.
> 286:      * If multiple operations are registered on the same observableList, they will be performed in the

For "observableList" I would use "observable list" similar to what was done with the other methods.

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

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


More information about the openjfx-dev mailing list