if ((Component) root == current) root = current.getFocusCycleRootAncestor ();     if (current instanceof Window) return getFirstComponent ((Container) current);  Container parent = current.getParent ();  synchronized (parent.getTreeLock ()) { Component[] components = parent.getComponents (); int componentIndex = 0; int numComponents = parent.getComponentCount ();   for (int i = 0; i < numComponents; i++) { if (components[i] == current) componentIndex = i; }   for (int i = componentIndex + 1; i < numComponents; i++) { if (accept (components[i])) return components[i];  if (components[i] instanceof Container) { Component result = getFirstComponent ((Container) components[i]);  if (result != null && implicitDownCycleTraversal) return result; } }    Component result = getComponentAfter (root, parent);  return result; } }
  public Component getComponentAfter(Container root, Component current)  {    return null;  }