diff --git a/src/share/classes/javax/swing/JApplet.java b/src/share/classes/javax/swing/JApplet.java index acb0203542009724450b0ea1945002967411d7e2..831a4b3adfa9d0e0b93893e9ca39696fc3375cf5 100644 --- a/src/share/classes/javax/swing/JApplet.java +++ b/src/share/classes/javax/swing/JApplet.java @@ -46,9 +46,10 @@ import javax.accessibility.*; * java.applet.Applet. JApplet contains a * JRootPane as its only child. The contentPane * should be the parent of any children of the JApplet. - * As a convenience add and its variants, remove and - * setLayout have been overridden to forward to the - * contentPane as necessary. This means you can write: + * As a convenience, the {@code add}, {@code remove}, and {@code setLayout} + * methods of this class are overridden, so that they delegate calls + * to the corresponding methods of the {@code ContentPane}. + * For example, you can add a child component to an applet as follows: *
  *       applet.add(child);
  * 
diff --git a/src/share/classes/javax/swing/JDialog.java b/src/share/classes/javax/swing/JDialog.java index 2e4b2b72efdcb6e4b1f75295abbd49d21a98e613..90dcd401d1fba9c780b8247c2b7e38a0b8404926 100644 --- a/src/share/classes/javax/swing/JDialog.java +++ b/src/share/classes/javax/swing/JDialog.java @@ -44,9 +44,10 @@ import javax.accessibility.*; * as its only child. * The {@code contentPane} should be the parent of any children of the * {@code JDialog}. - * As a convenience {@code add} and its variants, {@code remove} and - * {@code setLayout} have been overridden to forward to the - * {@code contentPane} as necessary. This means you can write: + * As a convenience, the {@code add}, {@code remove}, and {@code setLayout} + * methods of this class are overridden, so that they delegate calls + * to the corresponding methods of the {@code ContentPane}. + * For example, you can add a child component to a dialog as follows: *
  *       dialog.add(child);
  * 
diff --git a/src/share/classes/javax/swing/JFrame.java b/src/share/classes/javax/swing/JFrame.java index 038c63b122ade79b067cfe194f942d14e0305a2c..bf917bc83f6997db31f57e56cf8943ae53352b1b 100644 --- a/src/share/classes/javax/swing/JFrame.java +++ b/src/share/classes/javax/swing/JFrame.java @@ -50,9 +50,10 @@ import javax.accessibility.*; * as a rule, contain * all the non-menu components displayed by the JFrame. * This is different from the AWT Frame case. - * As a conveniance add and its variants, remove and - * setLayout have been overridden to forward to the - * contentPane as necessary. This means you can write: + * As a convenience, the {@code add}, {@code remove}, and {@code setLayout} + * methods of this class are overridden, so that they delegate calls + * to the corresponding methods of the {@code ContentPane}. + * For example, you can add a child component to a frame as follows: *
  *       frame.add(child);
  * 
diff --git a/src/share/classes/javax/swing/JInternalFrame.java b/src/share/classes/javax/swing/JInternalFrame.java index ad78df11c0186c10993b0c6722969f0ebbc14ec7..bbf0d762df5b55e739d248b534a0c8f7c408aef1 100644 --- a/src/share/classes/javax/swing/JInternalFrame.java +++ b/src/share/classes/javax/swing/JInternalFrame.java @@ -63,9 +63,10 @@ import sun.swing.SwingUtilities2; *

* The JInternalFrame content pane * is where you add child components. - * As a conveniance add and its variants, remove and - * setLayout have been overridden to forward to the - * contentPane as necessary. This means you can write: + * As a convenience, the {@code add}, {@code remove}, and {@code setLayout} + * methods of this class are overridden, so that they delegate calls + * to the corresponding methods of the {@code ContentPane}. + * For example, you can add a child component to an internal frame as follows: *

  *       internalFrame.add(child);
  * 
diff --git a/src/share/classes/javax/swing/JWindow.java b/src/share/classes/javax/swing/JWindow.java index c49e942b9aa8cbd149fcaf061b6ed30b40778131..f3fa8d4ace685d47a6f87caa20e8babb010e26dd 100644 --- a/src/share/classes/javax/swing/JWindow.java +++ b/src/share/classes/javax/swing/JWindow.java @@ -43,9 +43,10 @@ import javax.accessibility.*; * The JWindow component contains a JRootPane * as its only child. The contentPane should be the parent * of any children of the JWindow. - * As a conveniance add and its variants, remove and - * setLayout have been overridden to forward to the - * contentPane as necessary. This means you can write: + * As a convenience, the {@code add}, {@code remove}, and {@code setLayout} + * methods of this class are overridden, so that they delegate calls + * to the corresponding methods of the {@code ContentPane}. + * For example, you can add a child component to a window as follows: *
  *       window.add(child);
  * 
diff --git a/src/share/classes/javax/swing/RootPaneContainer.java b/src/share/classes/javax/swing/RootPaneContainer.java index 8405015a989e063b5c20f11a53adb686b08af918..8f4405faf3379845dccf5b92e02e670276d7eadb 100644 --- a/src/share/classes/javax/swing/RootPaneContainer.java +++ b/src/share/classes/javax/swing/RootPaneContainer.java @@ -45,18 +45,18 @@ import java.awt.Container; * dropping a component on a RootPaneContainer would be interpreted * as frame.getContentPane().add(child). *

- * For conveniance - * JFrame, JDialog, JWindow, - * JApplet and JInternalFrame, by default, - * forward, by default, all calls to the add, - * remove and setLayout methods, to the - * contentPane. This means you can call: + * As a convenience, the standard classes that implement this interface + * (such as {@code JFrame}, {@code JDialog}, {@code JWindow}, {@code JApplet}, + * and {@code JInternalFrame}) have their {@code add}, {@code remove}, + * and {@code setLayout} methods overridden, so that they delegate calls + * to the corresponding methods of the {@code ContentPane}. + * For example, you can add a child component to a frame as follows: *

- * rootPaneContainer.add(component);
+ *       frame.add(child);
  * 
* instead of: *
- * rootPaneContainer.getContentPane().add(component);
+ *       frame.getContentPane().add(child);
  * 
*

* The behavior of the add and