RFR: 8209788: Left/Right/Ctrl+A keys not working in editor of ComboBox if popup showing [v7]

Ambarish Rapte arapte at openjdk.java.net
Fri Aug 28 16:55:00 UTC 2020

On Fri, 28 Aug 2020 10:21:50 GMT, Jeanette Winzenburg <fastegal at openjdk.org> wrote:

> If the ComboBox is not editable, it will have the effect of making the HOME and END keys no-ops, which is a (possibly
> unwanted) change in behavior.

I have updated PR with changes for non editable ComboBox.
I could think of adding another property to propagate the editable property of ComboBox to ListViewBehavior. So now
this fix adds another property `editableComboBoxEditor`, not sure if there is other way to handle it. The change adds
HOME and END KeyMappings when ComboBox is non editable and removes them when ComboBox is editable. If the change sounds
Ok, I shall include test in next commit.

Also, there is one change in the if condition that was suggested by Jeanette before,
`if (!Boolean.TRUE.equals(control.getProperties().containsKey("excludeKeyMappingsForComboBoxEditor")))`
is changed to,
`if (Boolean.FALSE.equals(control.getProperties().containsKey("excludeKeyMappingsForComboBoxEditor")))`

It seems safe as `control.getProperties().containsKey()` returns either true or false.


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

More information about the openjfx-dev mailing list