Package org.pushingpixels.flamingo.api.common

Examples of org.pushingpixels.flamingo.api.common.JCommandButton.addActionListener()


        strip.setDisplayState(CommandButtonDisplayState.BIG);
        JCommandButton button = new JCommandButton(NbBundle.getMessage(DataTableTopComponent.class, "DataTableTopComponent.addColumnButton.text"), ImageWrapperResizableIcon.getIcon(ImageUtilities.loadImage("org/gephi/desktop/datalab/resources/table-insert-column.png", true), new Dimension(16, 16)));
        button.setCommandButtonKind(JCommandButton.CommandButtonKind.ACTION_ONLY);
        button.setDisplayState(CommandButtonDisplayState.BIG);
        if (classDisplayed == ClassDisplayed.NODE) {
            button.addActionListener(new ActionListener() {

                public void actionPerformed(ActionEvent e) {
                    showAddColumnUI(AddColumnUI.Mode.NODES_TABLE);
                }
            });
View Full Code Here


                public void actionPerformed(ActionEvent e) {
                    showAddColumnUI(AddColumnUI.Mode.NODES_TABLE);
                }
            });
        } else {
            button.addActionListener(new ActionListener() {

                public void actionPerformed(ActionEvent e) {
                    showAddColumnUI(AddColumnUI.Mode.EDGES_TABLE);
                }
            });
View Full Code Here

        strip.setDisplayState(CommandButtonDisplayState.BIG);
        JCommandButton button = new JCommandButton(NbBundle.getMessage(DataTableTopComponent.class, "DataTableTopComponent.mergeColumnsButton.text"), ImageWrapperResizableIcon.getIcon(ImageUtilities.loadImage("org/gephi/desktop/datalab/resources/merge.png", true), new Dimension(16, 16)));
        button.setCommandButtonKind(JCommandButton.CommandButtonKind.ACTION_ONLY);
        button.setDisplayState(CommandButtonDisplayState.BIG);
        if (classDisplayed == ClassDisplayed.NODE) {
            button.addActionListener(new ActionListener() {

                public void actionPerformed(ActionEvent e) {
                    showMergeColumnsUI(MergeColumnsUI.Mode.NODES_TABLE);
                }
            });
View Full Code Here

                public void actionPerformed(ActionEvent e) {
                    showMergeColumnsUI(MergeColumnsUI.Mode.NODES_TABLE);
                }
            });
        } else {
            button.addActionListener(new ActionListener() {

                public void actionPerformed(ActionEvent e) {
                    showMergeColumnsUI(MergeColumnsUI.Mode.EDGES_TABLE);
                }
            });
View Full Code Here

        button.setCommandButtonKind(JCommandButton.CommandButtonKind.ACTION_ONLY);
        if (m.getDescription() != null && !m.getDescription().isEmpty()) {
            button.setToolTipText(m.getDescription());
        }
        if (m.canExecute()) {
            button.addActionListener(new ActionListener() {

                public void actionPerformed(ActionEvent e) {
                    DataLaboratoryHelper.getDefault().executeManipulator(m);
                }
            });
View Full Code Here

  protected JCommandButton createActionButton(CommandButtonDisplayState state) {
    JCommandButton result = new JCommandButton(new edit_paste());
    result.setDisabledIcon(new FilteredResizableIcon(new edit_paste(),
        new ColorConvertOp(ColorSpace.getInstance(ColorSpace.CS_GRAY),
            null)));
    result.addActionListener(new ActionListener() {
      public void actionPerformed(ActionEvent e) {
        System.out.println(stamp() + ": Main paste");
      }
    });
    result
View Full Code Here

    result.setPopupCallback(new TestPopupCallback());
    result
        .setCommandButtonKind(JCommandButton.CommandButtonKind.ACTION_AND_POPUP_MAIN_ACTION);
    result.setDisplayState(state);
    result.setFlat(false);
    result.addActionListener(new ActionListener() {
      public void actionPerformed(ActionEvent e) {
        System.out.println(stamp() + ": Cut");
      }
    });
    return result;
View Full Code Here

    result.setPopupCallback(new TestPopupCallback());
    result
        .setCommandButtonKind(JCommandButton.CommandButtonKind.ACTION_AND_POPUP_MAIN_POPUP);
    result.setDisplayState(state);
    result.setFlat(false);
    result.addActionListener(new ActionListener() {
      public void actionPerformed(ActionEvent e) {
        System.out.println(stamp() + ": Copy");
      }
    });
    return result;
View Full Code Here

  @Override
  protected JCommandButton createActionButton(CommandButtonDisplayState state) {
    JCommandButton result = new JCommandButton(resourceBundle
        .getString("Paste.text"));
    result.setExtraText(resourceBundle.getString("Paste.textExtra"));
    result.addActionListener(new ActionListener() {
      public void actionPerformed(ActionEvent e) {
        System.out.println(stamp() + ": Main paste");
      }
    });
    result
View Full Code Here

    result.setPopupCallback(new TestPopupCallback());
    result
        .setCommandButtonKind(JCommandButton.CommandButtonKind.ACTION_AND_POPUP_MAIN_ACTION);
    result.setDisplayState(state);
    result.setFlat(false);
    result.addActionListener(new ActionListener() {
      public void actionPerformed(ActionEvent e) {
        System.out.println(stamp() + ": Cut");
      }
    });
    return result;
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.