Package com.ms.ui |
![]() Previous |
![]() Contents |
![]() Index |
![]() Next |
public interface IUIContainer { // Methods public int countChildren(); public void removeAllChildren(); public int continueInvalidate(); public boolean continueInvalidate(Component comp); public void fullValidate(Component comp); public Component navigate(Component comp, int direction, boolean keyable); public Component passFocus(Event e, int key); public Component getChild(int index); public Rectangle getClientRect(); public int getCompIndex(Component comp); public Component getComponent(Component comp); public Component getComponent(String name); public int getEdge(); public Component getFocusComp(); public Component getHeader(); public UILayoutManager getUILayout(); public void setEdge(int flags); public Component setHeader(Component header); }
Defines an interface for the extensions to the Container class.
public int continueInvalidate();Determines whether an invalidate of any child should invalidate this container as well, continuing the propogation
Return Value:
Returns 1 for continue, -1 for don't continue, or 0 to ask for each component
public boolean continueInvalidate(Component comp);Determines whether an invalidate of the specified child should invalidate this container as well, continuing the propogation.
Return Value:
Returns true for continue; false for don't continue.
Parameter Description comp The invalidated component.
public int countChildren();Retrieves the number of children in this object, not including the header child.
Return Value:
Returns the number of children in this object.
public void fullValidate(Component comp);Performs a validation from the outermost container effected by the given component's invalidation.
Return Value:
No return value.
Parameter Description comp The component to be validated.
public Component getChild(int index);Retrieves the specified child in this object.
Return Value:
Returns the child at the specified index.
Parameter Description index Index in the component array of the child object to retrieve.
public int getCompIndex(Component comp);Retrieves the component's index of the specified component.
Return Value:
Returns the location of the component in the container's component array.
Parameter Description comp The component whose index is to be retrieved.
public Component getComponent(Component comp);Retrieves the child component that contains the specified component in its hierarchy.
Return Value:
Returns the child of container that contains comp parameter, or null if comp parameter is not in this hierarchy.
Parameter Description comp The component from which to walk the ancestry chain.
public Component getComponent(String name);Retrieves the layout component identified by name.
Return Value:
Returns the specified component.
Parameter Description name The layout name that identifies the component to be retrieved.
public int getEdge();Retrieves the current edge flags that are used when drawing the container.
Return Value:
Returns the edge.
public Component getFocusComp();Retrieves the index of the component that has the focus.
Return Value:
Returns the focus index.
public Component getHeader();Retrieves the header (label) child of this object.
Return Value:
Returns the header child, or returns null if this object doesn't have one.
public UILayoutManager getUILayout();Retrieves the layout manager associated with the container.
Return Value:
Returns the layout manager object.
public Component navigate(Component comp, int direction, boolean keyable);Navigates to another component from the specified component in the given direction.
Return Value:
Returns the component navigated to, or null if no component in the specified direction exists.
Parameter Description comp The component from which to navigate. direction The direction (logically or spatially) to navigate. keyable If true, non-keyable components will be ignored during the navigation; otherwise, all components can be navigated to.
public Component passFocus(Event e, int key);Passes the focus to the appropriate component in the container, given the key pressed.
Return Value:
Returns the component that the focus was passed to.
Parameter Description e The event that was trapped. key The key that was pressed.
public void removeAllChildren();Remove all child containers.
Return Value:
No return values.
public void setEdge(int flags);Sets the edge flags for drawing the container.
Return Value:
No return value.
Parameter Description edge Flags specifying the type of container edge.
public Component setHeader(Component header);Makes the specified component the header object.
Return Value:
Returns the component that has become the header object.
Parameter Description header Component to become the header.
public Rectangle getClientRect();Retrieves the client rectangle for this component; the client rectangle is the rectangle that remains after the component's window rectangle is adjusted by the component's insets.
Return Value:
Returns the the bounding rectangle for the client area, in component's coordinates.
© 1997 Microsoft Corporation. All rights reserved. Legal Notices.