[JIRA] (GLAZEDLISTS-573) Unexpected behavior when unselected row is unselected

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

[JIRA] (GLAZEDLISTS-573) Unexpected behavior when unselected row is unselected

JIRA jira-no-reply@java.net
cwhite15 created GLAZEDLISTS-573:
------------------------------------

             Summary: Unexpected behavior when unselected row is unselected
                 Key: GLAZEDLISTS-573
                 URL: https://java.net/jira/browse/GLAZEDLISTS-573
             Project: glazedlists
          Issue Type: Bug
    Affects Versions: 1.9.0
         Environment: Java 7u51 64 bit
Windows 7 64 bit
            Reporter: cwhite15
            Assignee: jessewilson


Hi all,

I'm seeing some unexpected behavior from ListSelection.java when I unselect a row that's already unselected.  The anchor and lead selection is changed incorrectly, and an unnecessary ListSelectionEvent is fired.

To reproduce:

# I'm using a JXTable with Glazed Lists.
# Click on row n to select it.
# Click on row n+1 to select it.  Row n is unselected.
# Call AdvancedListSelectionModel.removeSelectionInterval(n, n).
# Debug through to ListSelection.deselect().  Notice that anchorSelectionIndex and leadSelectionIndex are updated to n+1.
# Debug through to the end of setSubRangeOfRange().  fireSelectionChanged is called even though the selection should not have changed.

Thanks,
Chris



--
This message was sent by Atlassian JIRA
(v6.2.3#6260)