public void componentHidden(final ComponentEvent e){
  final Object source=e.getSource();
  if (!(source instanceof JMenuItem))   return;
  setChildVisible((JMenuItem)source,false);
}

public void componentHidden ( final ComponentEvent e ) { final Object source = e . getSource ( ) ; if ( ! ( source instanceof JMenuItem ) ) return ; setChildVisible ( ( JMenuItem ) source , false ) ; }
invoked when the component has been made invisible . menucomponent . setvisible does nothing , so we remove the screenmenuitem from the screenmenu but leave it in fitems
