On Fri, 15 Jul 2022 09:07:07 GMT, John Hendrikx <[email protected]> wrote:
>> John Hendrikx has updated the pull request incrementally with one additional
>> commit since the last revision:
>>
>> Rename showing property to shown as it is already used in subclasses
>
> modules/javafx.base/src/main/java/javafx/beans/value/ObservableValue.java
> line 311:
>
>> 309: * @since 20
>> 310: */
>> 311: default ObservableValue<T> when(ObservableValue<Boolean> condition)
>> {
>
> Discussion: name? `when`, `conditionOn`, other suggestions? Note that this
> is not the same as a possible future method `filter`, as a `filter` would
> still keep observing its source at all times (and would use a `Predicate` as
> parameter).
`when` sounds fine, but we need to be careful about its relation to the `When`
class.
This reminds me also that some of the new functionality in `ObservableValue`
can be used as a replacement for `When`, maybe we should note that like we did
with `Bindings.select`.
-------------
PR: https://git.openjdk.org/jfx/pull/830