148 |
/** |
/** |
149 |
* Returns the component at the specified index. |
* Returns the component at the specified index. |
150 |
* |
* |
151 |
* @param index The index of the component to retrieve. |
* @param n The index of the component to retrieve. |
152 |
* |
* |
153 |
* @return The requested component. |
* @return The requested component. |
154 |
* |
* |
232 |
* Adds the specified component to this container at the end of the |
* Adds the specified component to this container at the end of the |
233 |
* component list. |
* component list. |
234 |
* |
* |
235 |
* @param component The component to add to the container. |
* @param comp The component to add to the container. |
236 |
* |
* |
237 |
* @return The same component that was added. |
* @return The same component that was added. |
238 |
*/ |
*/ |
248 |
* <code>add(Component, Object)</code>. |
* <code>add(Component, Object)</code>. |
249 |
* |
* |
250 |
* @param name The name of the component to be added. |
* @param name The name of the component to be added. |
251 |
* @param component The component to be added. |
* @param comp The component to be added. |
252 |
* |
* |
253 |
* @return The same component that was added. |
* @return The same component that was added. |
254 |
* |
* |
264 |
* Adds the specified component to this container at the specified index |
* Adds the specified component to this container at the specified index |
265 |
* in the component list. |
* in the component list. |
266 |
* |
* |
267 |
* @param component The component to be added. |
* @param comp The component to be added. |
268 |
* @param index The index in the component list to insert this child |
* @param index The index in the component list to insert this child |
269 |
* at, or -1 to add at the end of the list. |
* at, or -1 to add at the end of the list. |
270 |
* |
* |
283 |
* component list. The layout manager will use the specified constraints |
* component list. The layout manager will use the specified constraints |
284 |
* when laying out this component. |
* when laying out this component. |
285 |
* |
* |
286 |
* @param component The component to be added to this container. |
* @param comp The component to be added to this container. |
287 |
* @param constraints The layout constraints for this component. |
* @param constraints The layout constraints for this component. |
288 |
*/ |
*/ |
289 |
public void add(Component comp, Object constraints) |
public void add(Component comp, Object constraints) |
296 |
* in the component list. The layout manager will use the specified |
* in the component list. The layout manager will use the specified |
297 |
* constraints when layout out this component. |
* constraints when layout out this component. |
298 |
* |
* |
299 |
* @param component The component to be added. |
* @param comp The component to be added. |
300 |
* @param constraints The layout constraints for this component. |
* @param constraints The layout constraints for this component. |
301 |
* @param index The index in the component list to insert this child |
* @param index The index in the component list to insert this child |
302 |
* at, or -1 to add at the end of the list. |
* at, or -1 to add at the end of the list. |
315 |
* method. Any subclass doing this must call the superclass version of |
* method. Any subclass doing this must call the superclass version of |
316 |
* this method in order to ensure proper functioning of the container. |
* this method in order to ensure proper functioning of the container. |
317 |
* |
* |
318 |
* @param component The component to be added. |
* @param comp The component to be added. |
319 |
* @param constraints The layout constraints for this component, or |
* @param constraints The layout constraints for this component, or |
320 |
* <code>null</code> if there are no constraints. |
* <code>null</code> if there are no constraints. |
321 |
* @param index The index in the component list to insert this child |
* @param index The index in the component list to insert this child |
707 |
* a superclass method so that lightweight components are properly |
* a superclass method so that lightweight components are properly |
708 |
* drawn. |
* drawn. |
709 |
* |
* |
710 |
* @param graphics The graphics context for this paint job. |
* @param g The graphics context for this paint job. |
711 |
*/ |
*/ |
712 |
public void paint(Graphics g) |
public void paint(Graphics g) |
713 |
{ |
{ |
727 |
* a superclass method so that lightweight components are properly |
* a superclass method so that lightweight components are properly |
728 |
* drawn. |
* drawn. |
729 |
* |
* |
730 |
* @param graphics The graphics context for this update. |
* @param g The graphics context for this update. |
731 |
*/ |
*/ |
732 |
public void update(Graphics g) |
public void update(Graphics g) |
733 |
{ |
{ |
741 |
* a superclass method so that lightweight components are properly |
* a superclass method so that lightweight components are properly |
742 |
* drawn. |
* drawn. |
743 |
* |
* |
744 |
* @param graphics The graphics context for this print job. |
* @param g The graphics context for this print job. |
745 |
*/ |
*/ |
746 |
public void print(Graphics g) |
public void print(Graphics g) |
747 |
{ |
{ |
752 |
/** |
/** |
753 |
* Paints all of the components in this container. |
* Paints all of the components in this container. |
754 |
* |
* |
755 |
* @param graphics The graphics context for this paint job. |
* @param g The graphics context for this paint job. |
756 |
*/ |
*/ |
757 |
public void paintComponents(Graphics g) |
public void paintComponents(Graphics g) |
758 |
{ |
{ |
763 |
/** |
/** |
764 |
* Prints all of the components in this container. |
* Prints all of the components in this container. |
765 |
* |
* |
766 |
* @param graphics The graphics context for this print job. |
* @param g The graphics context for this print job. |
767 |
*/ |
*/ |
768 |
public void printComponents(Graphics g) |
public void printComponents(Graphics g) |
769 |
{ |
{ |
777 |
* |
* |
778 |
* @param listener The listener to add. |
* @param listener The listener to add. |
779 |
*/ |
*/ |
780 |
public synchronized void addContainerListener(ContainerListener l) |
public synchronized void addContainerListener(ContainerListener listener) |
781 |
{ |
{ |
782 |
containerListener = AWTEventMulticaster.add(containerListener, l); |
containerListener = AWTEventMulticaster.add(containerListener, listener); |
783 |
} |
} |
784 |
|
|
785 |
/** |
/** |
788 |
* |
* |
789 |
* @param listener The listener to remove. |
* @param listener The listener to remove. |
790 |
*/ |
*/ |
791 |
public synchronized void removeContainerListener(ContainerListener l) |
public synchronized void removeContainerListener(ContainerListener listener) |
792 |
{ |
{ |
793 |
containerListener = AWTEventMulticaster.remove(containerListener, l); |
containerListener = AWTEventMulticaster.remove(containerListener, listener); |
794 |
} |
} |
795 |
|
|
796 |
/** |
/** |
826 |
* <code>ContainerEvent</code>, otherwise it calls the superclass |
* <code>ContainerEvent</code>, otherwise it calls the superclass |
827 |
* method. |
* method. |
828 |
* |
* |
829 |
* @param event The event to be processed. |
* @param e The event to be processed. |
830 |
*/ |
*/ |
831 |
protected void processEvent(AWTEvent e) |
protected void processEvent(AWTEvent e) |
832 |
{ |
{ |
840 |
* Called when a container event occurs if container events are enabled. |
* Called when a container event occurs if container events are enabled. |
841 |
* This method calls any registered listeners. |
* This method calls any registered listeners. |
842 |
* |
* |
843 |
* @param event The event that occurred. |
* @param e The event that occurred. |
844 |
*/ |
*/ |
845 |
protected void processContainerEvent(ContainerEvent e) |
protected void processContainerEvent(ContainerEvent e) |
846 |
{ |
{ |
861 |
/** |
/** |
862 |
* AWT 1.0 event processor. |
* AWT 1.0 event processor. |
863 |
* |
* |
864 |
* @param event The event that occurred. |
* @param e The event that occurred. |
865 |
* |
* |
866 |
* @deprecated use {@link #dispatchEvent(AWTEvent)} instead |
* @deprecated use {@link #dispatchEvent(AWTEvent)} instead |
867 |
*/ |
*/ |
906 |
* unless the point does not exist within this container, in which |
* unless the point does not exist within this container, in which |
907 |
* case <code>null</code> is returned. |
* case <code>null</code> is returned. |
908 |
* |
* |
909 |
* @param point The point to return the component at. |
* @param x The x position of the point to return the component at. |
910 |
|
* @param y The y position of the point to return the component at. |
911 |
* |
* |
912 |
* @return The component containing the specified point, or <code>null</code> |
* @return The component containing the specified point, or <code>null</code> |
913 |
* if there is no such point. |
* if there is no such point. |
943 |
* unless the point does not exist within this container, in which |
* unless the point does not exist within this container, in which |
944 |
* case <code>null</code> is returned. |
* case <code>null</code> is returned. |
945 |
* |
* |
946 |
* @param point The point to return the component at. |
* @param p The point to return the component at. |
947 |
* @return The component containing the specified point, or <code>null</code> |
* @return The component containing the specified point, or <code>null</code> |
948 |
* if there is no such point. |
* if there is no such point. |
949 |
*/ |
*/ |
1019 |
* Tests whether or not the specified component is contained within |
* Tests whether or not the specified component is contained within |
1020 |
* this components subtree. |
* this components subtree. |
1021 |
* |
* |
1022 |
* @param component The component to test. |
* @param comp The component to test. |
1023 |
* |
* |
1024 |
* @return <code>true</code> if this container is an ancestor of the |
* @return <code>true</code> if this container is an ancestor of the |
1025 |
* specified component, <code>false</code> otherwise. |
* specified component, <code>false</code> otherwise. |
1058 |
* Writes a listing of this container to the specified stream starting |
* Writes a listing of this container to the specified stream starting |
1059 |
* at the specified indentation point. |
* at the specified indentation point. |
1060 |
* |
* |
1061 |
* @param stream The <code>PrintStream</code> to write to. |
* @param out The <code>PrintStream</code> to write to. |
1062 |
* @param indent The indentation point. |
* @param indent The indentation point. |
1063 |
*/ |
*/ |
1064 |
public void list(PrintStream out, int indent) |
public void list(PrintStream out, int indent) |
1075 |
* Writes a listing of this container to the specified stream starting |
* Writes a listing of this container to the specified stream starting |
1076 |
* at the specified indentation point. |
* at the specified indentation point. |
1077 |
* |
* |
1078 |
* @param stream The <code>PrintWriter</code> to write to. |
* @param out The <code>PrintWriter</code> to write to. |
1079 |
* @param indent The indentation point. |
* @param indent The indentation point. |
1080 |
*/ |
*/ |
1081 |
public void list(PrintWriter out, int indent) |
public void list(PrintWriter out, int indent) |