glazedlists
  1. glazedlists
  2. GLAZEDLISTS-506

Add ctr(EventList<E>, ListSelection<E>) to DefaultEventSelectionModel

    Details

    • Type: Improvement Improvement
    • Status: Open
    • Priority: Major Major
    • Resolution: Unresolved
    • Affects Version/s: current
    • Fix Version/s: milestone 1
    • Component/s: swing
    • Labels:
      None
    • Environment:

      Operating System: All
      Platform: All

    • Issuezilla Id:
      506

      Description

      I have a use case where I already have an EventList and a ListSelection and wish
      to wrap the ListSelection in a swing ListSelectionModel. It would be possible
      to use DefaultEventSelectionModel to do this if it were not final or had a
      constructor

      DefaultEventSelectionModel(final EventList<E> source, final ListSelection<E>
      listSelection)
      {
      source.getReadWriteLock().readLock().lock();
      try

      { this.source = source; this.listSelection = listSelection; this.listSelection.addSelectionListener(new SwingSelectionListener()); }

      finally

      { source.getReadWriteLock().readLock().unlock(); }

      }

      The constructor may also want to confirm that the source of the listSelection
      matches source.

        Activity

        There are no comments yet on this issue.

          People

          • Assignee:
            jessewilson
            Reporter:
            heuermh
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated: