<Swing Dev> [9] Review request for 8072767 DefaultCellEditor for comboBox creates ActionEvent with wrong source object
Alexander Zvegintsev
alexander.zvegintsev at oracle.com
Mon Apr 13 14:35:24 UTC 2015
Hello Alexandr,
The fix looks fine to me to.
--
Thanks,
Alexander.
On 03.04.2015 14:42, Alexander Scherbatiy wrote:
>
> Hello,
>
> Could you review the fix:
> bug: https://bugs.openjdk.java.net/browse/JDK-8072767
> webrev: http://cr.openjdk.java.net/~alexsch/8072767/webrev.00
>
> This is a regression from the fix 8019180 Use JComboBox as it's own
> ActionListener leads to unexpected behaviour
>
> JComboBox has unexpected behaviour if it is used as it's own
> ActionListener: the selected value is empty and
> the drop down popup is closed after each up/down key event.
>
> The original fix filters action events which source does not equal
> JComboBox editor or editor component.
> However, in case of the JTable the event source is DefaultCellEditor
> which is different from the JComboBox editors.
>
> The suggested solution is to revert the fix for the issue 8019180
> back and fix the JComboBox unexpected behaviour.
> - Update the editor value for the new selected item.
> - "JComboBox.isTableCellEditor" UIManager property can be used in
> a user application to avoid action events firing
> on each key navigation.
>
>
> Thanks,
> Alexandr.
>
More information about the swing-dev
mailing list