Container.getComponentAt
Class Overview | Class Members |
This Package |
All Packages
public Component getComponentAt( int x,
int y )
Parameters
- x
- the x coordinate
- y
- the y coordinate
Returns
null if the component does not contain the position.
If there is no child component at the requested point and the
point is within the bounds of the container the container itself
is returned; otherwise the top-most child is returned.
Description
Locates the component that contains the x,y position. The
top-most child component is returned in the case where there
is overlap in the components. This is determined by finding
the component closest to the index 0 that claims to contain
the given point via Component.contains().
Overrides
getComponentAt in class Component
See Also
contains