private void handleEnterEvent(MouseEvent event) {
    gotEnterAfterExit = true;

    ArrayList exitables = new ArrayList(enteredComponents);
    ArrayList enterables = new ArrayList();

    Component c = (Component) event.getSource();
    while (c != null) {
      if (hoverableComponents.contains(c)) {
        exitables.remove(c);
        enterables.add(c);
      }

      c = c.getParent();
    }

    if (enterables.size() > 0) {
      Object obj[] = enterables.toArray();
      for (int i = obj.length - 1; i >= 0; i--) {
        if (!((Hoverable) obj[i]).acceptHover(enterables)) {
          enterables.remove(obj[i]);
          exitables.add(obj[i]);
        }
      }
    }

    for (int i = exitables.size() - 1; i >= 0; i--) {
      dispatchExit((Hoverable) exitables.get(i));
    }

    for (int i = enterables.size() - 1; i >= 0; i--) {
      dispatchEnter((Hoverable) enterables.get(i));
    }
  }