RFR: 8090123: Items are no longer visible when collection is changed [v3]

Lukasz Kostyra lkostyra at openjdk.org
Tue Feb 21 13:30:39 UTC 2023


On Tue, 21 Feb 2023 06:05:54 GMT, Karthik P K <kpk at openjdk.org> wrote:

>> When a large number of items were scrolled in the `ChoiceBox`, the scrolled offset was carried forward when the list is replaced with small number of items. Hence the scroll up arrow was displayed with empty popup.
>> 
>> Changed code to scroll to top before popup display when content height of `ChoiceBox` is smaller than the scrolled offset.
>> 
>> Added system test to validate the fix.
>
> Karthik P K has updated the pull request incrementally with one additional commit since the last revision:
> 
>   Correctig typo in test name

> I couldn't reproduce this issue both in windows and mac. Could you please give more details on this.

I rerun whole tests a few more times today on both platforms, each time with:


./gradlew clean
./gradlew sdk apps
./gradlew --continue --info -PFULL_TEST=true -PUSE_ROBOT=true test


On both platforms the results varied, sometimes it passed, others it failed. When it failed, it was assertions on `ChoiceBoxScrollUpOnCollectionChangeTest.java` @ line 131 or 132 (again, it wasn't consistently the same). I guess there is some sort of weird race condition going on.

As for environment details, on both systems I run tests on JDK 19.0.2. OS versions are macOS 12.6.1, Windows 11 22H2. Mac has default Retina XDR settings and scaling, Windows 11 machine has native resolution and 100% scaling. I made sure machines are awake and not turn the display off, screen save or go to sleep during tests. Also I made sure to not touch the mouse/trackpad on either one for the duration of the test.

I guess this would require checking it more in depth on someone else's machines. I'm not 100% sure what would cause this, since it's not consistent result it could be as well something in my environment that makes that specific test fail on some occasions.

Other than that, LGTM. However I think someone more experienced should take a closer look at it in order to approve it.

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

PR: https://git.openjdk.org/jfx/pull/1039


More information about the openjfx-dev mailing list