Package javax.swing

Examples of javax.swing.DefaultListModel


        }
        getConfiguration().setEnabled(enableCheckBox.isSelected());
    }

    public void resetChanges() {
        DefaultListModel model = new DefaultListModel();
        for (CodeCompletionSortingItem sortingItem : getConfiguration().getSortingItems()) {
            model.addElement(sortingItem);
        }
        sortingItemsList.setModel(model);
        enableCheckBox.setSelected(getConfiguration().isEnabled());
        sortingItemsList.setEnabled(getConfiguration().isEnabled());
        sortingItemsList.setBackground(
View Full Code Here


                    }
                }
            }
        };

        DefaultListModel model = new DefaultListModel();
        for (T element : elements) {
            Entry<T> entry = new Entry<T>(element);
            model.addElement(entry);
        }
        setModel(model);

        addMouseListener(mouseAdapter);
View Full Code Here

                @Override
                public int compare(Entry<T> o1, Entry<T> o2) {
                    return comparator.compare(o1.presentable, o2.presentable);
                }
            });
        DefaultListModel newModel = new DefaultListModel();
        for (Entry<T> entry : entries) {
            newModel.addElement(entry);
        }
        setModel(newModel);
    }
View Full Code Here

        }
        return changed;
    }

    public void addActionListener(ActionListener actionListener) {
        DefaultListModel model = (DefaultListModel) getModel();
        for (Object o : model.toArray()) {
            Entry entry = (Entry) o;
            entry.checkBox.addActionListener(actionListener);
        }
    }
View Full Code Here

            entry.checkBox.addActionListener(actionListener);
        }
    }

    public void removeActionListener(ActionListener actionListener) {
        DefaultListModel model = (DefaultListModel) getModel();
        for (Object o : model.toArray()) {
            Entry entry = (Entry) o;
            entry.checkBox.removeActionListener(actionListener);
        }
    }
View Full Code Here

        EventManager.subscribe(project, TransactionListener.TOPIC, this);
    }

    private void updateListModel() {
        DefaultListModel model = new DefaultListModel();
        ConnectionManager connectionManager = ConnectionManager.getInstance(project);
        for (ConnectionBundle connectionBundle : connectionManager.getConnectionBundles()) {
            for (ConnectionHandler connectionHandler : connectionBundle.getConnectionHandlers()) {
                if (connectionHandler.hasUncommittedChanges()) {
                    connectionHandlers.add(connectionHandler);
                    model.addElement(connectionHandler);
                }
            }
        }

        connectionsList.setModel(model);
        if (model.size() > 0) {
            connectionsList.setSelectedIndex(0);
        }
    }
View Full Code Here

        Project project = connectionHandler.getProject();
        FileConnectionMappingManager connectionMappingManager = FileConnectionMappingManager.getInstance(project);
        DBSchema currentSchema = connectionMappingManager.getCurrentSchema(virtualFile);

        List<DBSchema> schemas = connectionHandler.getObjectBundle().getSchemas();
        DefaultListModel model = new DefaultListModel();

        for (DBSchema schema : schemas) {
            model.addElement(schema);
        }
        schemasList.setModel(model);
        schemasList.setSelectedValue(currentSchema, true);
    }
View Full Code Here

      fProgressIndicator= new MacProgressBar(fStatusLine);
    else                                                           
    fProgressIndicator= new ProgressBar();
    fCounterPanel= createCounterPanel();

    fFailures= new DefaultListModel();

    fTestViewTab= createTestRunViews();
    JPanel failedPanel= createFailedPanel();

    fFailureView= createFailureDetailView();
View Full Code Here

    private JButton selectSkinDir = null;
    private static SkinPreference instance = null;

    private SkinPreference()
    {
        listModel = new DefaultListModel();
    }
View Full Code Here

    private JPanel extensionPane = null;
    private static TypePreference instance = null;

    private TypePreference()
    {
        listModel = new DefaultListModel();
    }
View Full Code Here

TOP

Related Classes of javax.swing.DefaultListModel

Copyright © 2018 www.massapicom. 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.