public void remove(MenuComponent item){
synchronized (getTreeLock()) {
    int index=items.indexOf(item);
    if (index >= 0) {
      remove(index);
    }
  }
}

public void remove ( MenuComponent item ) { synchronized ( getTreeLock ( ) ) { int index = items . indexOf ( item ) ; if ( index >= 0 ) { remove ( index ) ; } } }
removes the specified menu item from this menu .
