Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-4421477

JList.setSelectionMode() doc: note that settings come from ListSelectionModel

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: P3 P3
    • 1.4.0
    • 1.3.0
    • docs
    • beta
    • generic
    • generic



      Name: krC82822 Date: 03/03/2001


      orig synopsis: "api doc: incomplete JList reference to ListSelectionModel"

      The description of JList.setSelectionMode() mentions several valid
      int values (possible modes), but does not note to which class they
      belong.

      I had to hunt down ListSelectionModel to find these values.

      ----------------

      "setSelectionMode

      public void setSelectionMode(int selectionMode)

            Determines whether single-item or multiple-item selections are allowed. The following selectionMode values are allowed:
                  SINGLE_SELECTION Only one list index can be selected at a time. In this mode the setSelectionInterval and
                  addSelectionInterval methods are equivalent, and only the second index argument is used.
                  SINGLE_INTERVAL_SELECTION One contiguous index interval can be selected at a time. In this mode
                  setSelectionInterval and addSelectionInterval are equivalent.
                  MULTIPLE_INTERVAL_SELECTION In this mode, there's no restriction on what can be selected. This is the default.
            Parameters:
                  selectionMode - an integer specifying the type of selections that are permissible
            See Also:
                  getSelectionMode()"





      (Review ID: 118064)
      ======================================================================

            sharonz Sharon Zakhour (Inactive)
            kryansunw Kevin Ryan (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: