Package ch.rakudave.jnetmap.plugins

Examples of ch.rakudave.jnetmap.plugins.Notifier


    @Override
    public Component getListCellRendererComponent(JList list, Object value, int index, boolean isSelected, boolean cellHasFocus) {
      JLabel label = (JLabel) super.getListCellRendererComponent(list,
          value, index, isSelected, cellHasFocus);
      if (value == null) return label;
      Notifier l = (Notifier) value;
      label.setText((showName)?l.getPluginName()+": "+l.getName():l.getPluginName());
      label.setIcon(l.getIcon());
      return label;
    }
View Full Code Here


        JButton addListener = new JButton(Lang.get("action.add"), Icons.get("add"));
          addListener.setPreferredSize(new Dimension(100, 30));
          addListener.addActionListener(new ActionListener() {
            @Override
            public void actionPerformed(ActionEvent e) {
              Notifier newListener = ((Notifier) addSelector.getSelectedItem()).create();
              m.addStatusListener(newListener);
              newListener.showPropertiesWindow(owner, true);
              listenerList.setListData(new Vector<Notifier>(m.getStatusListeners()));
            }
          });
        addWrapper.add(addSelector, BorderLayout.CENTER);
        addWrapper.add(addListener, BorderLayout.EAST);
View Full Code Here

TOP

Related Classes of ch.rakudave.jnetmap.plugins.Notifier

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.