selectedItem = getElementAt(selected);
selectedItem = getElementAt(selected + 1);
  public void removeElementAt(int index)  {    int selected = getIndexOf(selectedItem);    list.remove(index);    if (selected == index) // choose a new selected item      {        if (selected > 0)          selectedItem = getElementAt(selected - 1);        else           selectedItem = getElementAt(selected);      }    fireIntervalRemoved(this, index, index);  }