<Swing Dev> RFR: 8264218: Public method javax.swing.JMenu.setComponentOrientation() has no spec
Alexey Ivanov
aivanov at openjdk.java.net
Thu Apr 1 12:52:39 UTC 2021
On Fri, 26 Mar 2021 11:30:35 GMT, Prasanta Sadhukhan <psadhukhan at openjdk.org> wrote:
> A public overriding method JMenu.setComponentOrientation(java.awt.ComponentOrientation)
> has no spec.
> Added spec for the method.
src/java.desktop/share/classes/javax/swing/JMenu.java line 1269:
> 1267: * </ul>
> 1268: * @see java.awt.ComponentOrientation
> 1269: */
Shall it just use `{@inheritDoc}`?
The javadoc generated in 7 and 8 does exactly this.
However, the new text explicitly mentions that this method changes not only orientation of this component but also of the associated popup menu.
I do not think the description of the parameter has to list all the values of `ComponentOrientation`, these are the only publicly available values any way. If a value is added in the future, the javadoc will become incorrect.
-------------
PR: https://git.openjdk.java.net/jdk/pull/3213
More information about the swing-dev
mailing list