Examples of ListSelectionModel


Examples of javax.swing.ListSelectionModel


  private void configurePanelWithoutSelection()
  {
    final JLabel columnsLabel = new JLabel(UtilMessages.getInstance().getString("ArrayCellEditorDialog.SelectedItems"));
    final ListSelectionModel selectionModel = table.getSelectionModel();

    final Action addGroupAction = new AddEntryAction(tableModel);
    final Action removeGroupAction = new RemoveEntryAction(tableModel, selectionModel);
    final Action sortUpAction = new SortBulkUpAction(tableModel, selectionModel, table);
    final Action sortDownAction = new SortBulkDownAction(tableModel, selectionModel, table);
View Full Code Here

Examples of nextapp.echo2.app.list.ListSelectionModel

                testTable.getSelectionModel().setSelectionMode(ListSelectionModel.MULTIPLE_SELECTION);
            }
        });
        controlsColumn.addButton("Toggle Selection of Row #2", new ActionListener() {
            public void actionPerformed(ActionEvent e) {
                ListSelectionModel selectionModel = testTable.getSelectionModel();
                selectionModel.setSelectedIndex(2, !selectionModel.isSelectedIndex(2));
            }
        });
        controlsColumn.addButton("Toggle Selection of Row #500 (there isn't one)", new ActionListener() {
            public void actionPerformed(ActionEvent e) {
                ListSelectionModel selectionModel = testTable.getSelectionModel();
                selectionModel.setSelectedIndex(500, !selectionModel.isSelectedIndex(500));
            }
        });
        controlsColumn.addButton("Set Selection Foreground", new ActionListener() {
            public void actionPerformed(ActionEvent e) {
                testTable.setSelectionForeground(StyleUtil.randomColor());
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.