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

TreeView: wrong return of treeView.getSelectionModel().getSelectedItem()

    Details

      Description

      With multi-selection mode, if a listener of selection mode cleared the last clicked item without shift-down, the item was still returned by treeView.getSelectionModel().getSelectedItem() and used as the based item for multi-selection.

      1) clicked on item A,
      2) clicked on item B with shift-down, at same time my listener is waked up to do some filtering, it called:
                     *) treeView.getSelectionModel().clearSelection()
                     *) treeView.getSelectionModel().select(B)
      3) clicked on item C with shift-down
          the result was that multi-selection was done with the base item A! and A was selected.
       

        Attachments

          Activity

            People

            • Assignee:
              jgiles Jonathan Giles
              Reporter:
              sjiang Shanliang Jiang (Inactive)
            • Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:
                Imported: