diff options
author | Andrew John Hughes <gnu_andrew@member.fsf.org> | 2006-10-05 02:44:18 +0000 |
---|---|---|
committer | Andrew John Hughes <gnu_andrew@member.fsf.org> | 2006-10-05 02:44:18 +0000 |
commit | 2799793789d5b66c90efbd1a3eb56e0c1ec57f88 (patch) | |
tree | 9157197f502b6830af9cafe029fd3d47628a7ed6 /javax/swing/JMenuBar.java | |
parent | 7516107c5abe26f7a4378017344eb9e449ebc28e (diff) | |
download | classpath-2799793789d5b66c90efbd1a3eb56e0c1ec57f88.tar.gz |
2006-10-05 Andrew John Hughes <gnu_andrew@member.fsf.org>
* Merge of HEAD-->generics for 2006/09/03-2006/10/04.
Diffstat (limited to 'javax/swing/JMenuBar.java')
-rw-r--r-- | javax/swing/JMenuBar.java | 33 |
1 files changed, 19 insertions, 14 deletions
diff --git a/javax/swing/JMenuBar.java b/javax/swing/JMenuBar.java index 35f129377..73b409e42 100644 --- a/javax/swing/JMenuBar.java +++ b/javax/swing/JMenuBar.java @@ -298,19 +298,25 @@ public class JMenuBar extends JComponent implements Accessible, MenuElement } /** - * DOCUMENT ME! + * This method is not implemented and will throw an {@link Error} if called. * - * @return DOCUMENT ME! + * @return This method never returns anything, it throws an exception. */ public JMenu getHelpMenu() { - return null; + // the following error matches the behaviour of the reference + // implementation... + throw new Error("getHelpMenu() is not implemented"); } /** - * Returns margin betweeen menu bar's border and its menues + * Returns the margin between the menu bar's border and its menus. If the + * margin is <code>null</code>, this method returns + * <code>new Insets(0, 0, 0, 0)</code>. * - * @return margin between menu bar's border and its menues + * @return The margin (never <code>null</code>). + * + * @see #setMargin(Insets) */ public Insets getMargin() { @@ -617,21 +623,20 @@ public class JMenuBar extends JComponent implements Accessible, MenuElement } /** - * Sets the menu bar's "margin" bound property, which represents - * distance between the menubar's border and its menus. - * icon. When marging property is modified, PropertyChangeEvent will - * be fired to menuBar's PropertyChangeListener's. - * - * @param m distance between the menubar's border and its menus. + * Sets the margin between the menu bar's border and its menus (this is a + * bound property with the name 'margin'). * + * @param m the margin (<code>null</code> permitted). + * + * @see #getMargin() */ public void setMargin(Insets m) { if (m != margin) { - Insets oldMargin = margin; - margin = m; - firePropertyChange("margin", oldMargin, margin); + Insets oldMargin = margin; + margin = m; + firePropertyChange("margin", oldMargin, margin); } } |