public static Component getRootParent ( Component component ) { while ( null != component . getParent ( ) ) { component = component . getParent ( ) ; } return component ; }
Gets the root parent from the given Component Object .