defaultListSelectionModel.addListSelectionListener(new ListSelectionListener() { @Override public void valueChanged(ListSelectionEvent e) {
public ListToTreeSelectionModelWrapper(JTree tree) { super(); this.tree = tree; listSelectionModel.addListSelectionListener(new ListSelectionListener() { @Override public void valueChanged(ListSelectionEvent e) { if (!e.getValueIsAdjusting()){ updateSelectedPathsFromSelectedRows(); } } }); }
public void addListSelectionListener(ListSelectionListener l) { super.addListSelectionListener(l); }
/** Creates a new instance of TaskModel */ public TaskModel() { selectionModel = new DefaultListSelectionModel(); model = new DefaultListModel(); dataListeners = new LinkedHashSet<ListDataListener>(); selectionListeners = new LinkedHashSet<ListSelectionListener>(); TaskListener list = new TaskListener(); model.addListDataListener(list); selectionModel.addListSelectionListener(list); }
protected void createSelectionModelQueueTable() { $objectMap.put("selectionModelQueueTable", selectionModelQueueTable = new DefaultListSelectionModel()); selectionModelQueueTable.addListSelectionListener(JAXXUtil.getEventListener(ListSelectionListener.class, "valueChanged", this, "doValueChanged__on__selectionModelQueueTable")); }
protected void createSelectionModelQueueTableDone() { $objectMap.put("selectionModelQueueTableDone", selectionModelQueueTableDone = new DefaultListSelectionModel()); selectionModelQueueTableDone.addListSelectionListener(JAXXUtil.getEventListener(ListSelectionListener.class, "valueChanged", this, "doValueChanged__on__selectionModelQueueTableDone")); }
SAMSpectralFormModel(AppContext appContext, SpectralAngleMapperForm samForm) { this.appContext = appContext; this.samForm = samForm; spectrumListModel = new DefaultListModel<>(); spectrumListSelectionModel = new DefaultListSelectionModel(); spectrumListSelectionModel.setSelectionMode(ListSelectionModel.MULTIPLE_INTERVAL_SELECTION); spectrumListSelectionModel.addListSelectionListener(new EndmemberListSelectionListener()); propertyChangeSupport = new PropertyChangeSupport(this); }
public FudaaDjaFormListener(final FudaaReportFrameController _controller) { super(); controller_ = _controller; controller_.grid_.addGridListener(this); selectionListener_ = new HashSet(); model_ = new DefaultListSelectionModel(); updateFromDja(); model_.addListSelectionListener(this); }
/** * Updates the selection model of the table list with a custom model. * * @param selectionListener custom selection listener. */ private void updateListenerList(ListSelectionListener selectionListener) { DefaultListSelectionModel listSelectionModel = (DefaultListSelectionModel) _table.getSelectionModel(); EventListener[] listeners = (EventListener[]) listSelectionModel.getListeners( ListSelectionListener.class).clone(); for (int i = 0; i < listeners.length; i++) { listSelectionModel.removeListSelectionListener( (ListSelectionListener) listeners[i]); } // add the custom listener first, so it will be notified last listSelectionModel.addListSelectionListener(selectionListener); for (int i = 0; i < listeners.length; i++) { listSelectionModel.addListSelectionListener( (ListSelectionListener) listeners[i]); } }
public EndmemberFormModel(AppContext appContext) { this.appContext = appContext; endmemberListModel = new DefaultListModel<>(); endmemberListSelectionModel = new DefaultListSelectionModel(); endmemberListSelectionModel.setSelectionMode(ListSelectionModel.SINGLE_SELECTION); endmemberListModel.addListDataListener(new EndmemberListDataListener()); endmemberListSelectionModel.addListSelectionListener(new EndmemberListSelectionListener()); endmemberDiagram = new Diagram(); endmemberDiagram.setXAxis(new DiagramAxis("Wavelength", "")); endmemberDiagram.setYAxis(new DiagramAxis("Radiation", "")); endmemberDiagram.setDrawGrid(false); propertyChangeSupport = new PropertyChangeSupport(this); }
public EndmemberFormModel(AppContext appContext) { this.appContext = appContext; endmemberListModel = new DefaultListModel(); endmemberListSelectionModel = new DefaultListSelectionModel(); endmemberListSelectionModel.setSelectionMode(ListSelectionModel.SINGLE_SELECTION); endmemberListModel.addListDataListener(new EndmemberListDataListener()); endmemberListSelectionModel.addListSelectionListener(new EndmemberListSelectionListener()); endmemberDiagram = new Diagram(); endmemberDiagram.setXAxis(new DiagramAxis("Wavelength", "")); endmemberDiagram.setYAxis(new DiagramAxis("Radiation", "")); endmemberDiagram.setDrawGrid(false); propertyChangeSupport = new PropertyChangeSupport(this); }