RFR: 8276553: ListView scrollTo() is broken after fix for JDK-8089589
Jeanette Winzenburg
fastegal at openjdk.java.net
Mon Nov 29 16:58:06 UTC 2021
On Mon, 29 Nov 2021 14:38:10 GMT, Michael Strauß <mstrauss at openjdk.org> wrote:
>> After (re)setting the number of elements, make sure to do at least some estimation of the total size.
>> Added a testcase for this scenario.
>
> modules/javafx.controls/src/main/java/javafx/scene/control/skin/VirtualFlow.java line 903:
>
>> 901: recalculateAndImproveEstimatedSize(2);
>> 902:
>> 903: cellCount.set(value);
>
> Can this be implemented in a way that doesn't violate the property contract? Since this property is public API, `setCellCount(int)` should just call `cellCountProperty().set(int)`. Maybe you can extract the composite operation here into a private method and use that instead of `setCellCount(int)`.
>
> `position` has the same problem.
good catch! the "additional" stuff typically is done in the properties' invalidated ..
-------------
PR: https://git.openjdk.java.net/jfx/pull/683
More information about the openjfx-dev
mailing list