On Wed, 20 May 2026 05:19:36 GMT, Christopher Schnick <[email protected]> 
wrote:

>> This is a follow-up to the combobox converter PR. It seems like the 
>> updateDisplayNode method in the Skin does not properly handle null cases for 
>> when null is an item in the combobox. It probably incorrectly assumes that 
>> any null values is mapped to null by the stringconverter. However, if you 
>> create a custom converter, a null value can have a non-null string value.
>> 
>> ---------
>> - [x] I confirm that I make this contribution in accordance with the 
>> [OpenJDK Interim AI Policy](https://openjdk.org/legal/ai).
>
> Christopher Schnick has updated the pull request incrementally with one 
> additional commit since the last revision:
> 
>   Fix null handling for text field

Two minor improvements in the test - otherwise looks good and all my tests were 
successful.

modules/javafx.controls/src/test/java/test/javafx/scene/control/ComboBoxTest.java
 line 399:

> 397: 
> 398:         ListCell<String> cell = (ListCell<String>) 
> ((ComboBoxListViewSkin<String>) comboBox.getSkin())
> 399:                 .getDisplayNode();

Just call and cast `getDisplayNode();` directly

modules/javafx.controls/src/test/java/test/javafx/scene/control/ComboBoxTest.java
 line 449:

> 447: 
> 448:         ListCell<String> cell = (ListCell<String>) 
> ((ComboBoxListViewSkin<String>) comboBox.getSkin())
> 449:                 .getDisplayNode();

Just call and cast `getDisplayNode();` directly

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

PR Review: https://git.openjdk.org/jfx/pull/2169#pullrequestreview-4345040425
PR Review Comment: https://git.openjdk.org/jfx/pull/2169#discussion_r3288041191
PR Review Comment: https://git.openjdk.org/jfx/pull/2169#discussion_r3288041999

Reply via email to