Beispiel #1
0
  /**
   * This method ensures that the item at the specified index is visible.
   *
   * @exception IllegalArgumentException If the specified index is out of range.
   */
  public synchronized void makeVisible(int index) throws IllegalArgumentException {
    if ((index < 0) || (index >= items.size()))
      throw new IllegalArgumentException("Bad list index: " + index);

    visibleIndex = index;
    if (peer != null) {
      ListPeer l = (ListPeer) peer;
      l.makeVisible(index);
    }
  }