Skip to main content


No replies


I just went through the BasicComboBoxUI and I had a doubt regarding the accessible information of the ComboBoxEditor.

We are setting the AccessibleParent of the ComboBoxEditor at 2 places:
1. BasicComboBoxUI.configureEditor() and
2. BasicComboBoxUI.getAccessibleChild().

Why do we need to do this and thats too at 2 places.

Doc of AccessibleContext.setAccessibleName() says that,
"Sets the Accessible parent of this object. This is meant to be used only in the situations where the actual component's parent should not be treated as the component's accessible parent and is a method that should only be called by the parent of the accessible child."

In this case the parent of the editor is the ComboBox, then why do we need to set it again.

Even if we set to overcome some bug (or something) why is that we set it at two places. Won't it be enough if we do it in configureEditor() alone.