Package javax.swing

Examples of javax.swing.JCheckBox.addActionListener()


      }
    });

    final JCheckBox isFlat = new JCheckBox("is flat");
    isFlat.setSelected(true);
    isFlat.addActionListener(new ActionListener() {
      public void actionPerformed(ActionEvent e) {
        splitPane.putClientProperty(SubstanceLookAndFeel.FLAT_PROPERTY,
            (isFlat.isSelected() ? Boolean.TRUE : Boolean.FALSE));
        splitPane.repaint();
      }
View Full Code Here


    });

    final JCheckBox isVertical = new JCheckBox("is vertical");
    splitPane.setOrientation(JSplitPane.VERTICAL_SPLIT);
    isVertical.setSelected(true);
    isVertical.addActionListener(new ActionListener() {
      public void actionPerformed(ActionEvent e) {
        splitPane
            .setOrientation(isVertical.isSelected() ? JSplitPane.VERTICAL_SPLIT
                : JSplitPane.HORIZONTAL_SPLIT);
      }
View Full Code Here

      }
    });

    final JCheckBox isEnabled = new JCheckBox("is enabled");
    isEnabled.setSelected(true);
    isEnabled.addActionListener(new ActionListener() {
      public void actionPerformed(ActionEvent e) {
        splitPane.setEnabled(isEnabled.isSelected());
      }
    });
View Full Code Here

    private JCheckBox addFilterLogCheckBox(String type, String name, String methodName, boolean defaultValue) {
        m_FilterMethod.put(type, methodName);
        JCheckBox checkBox = new JCheckBox(name);
        checkBox.setSelected(defaultValue);
        checkBox.setName(name);
        checkBox.addActionListener(new ActionListener() {

            public void actionPerformed(ActionEvent e) {
                Rectangle visibleRect = m_LogTable.getVisibleRect();

                // get top fully visible row in view
View Full Code Here

                    }
                }
            });

            // when unselecting "QTaste" force "Invoking" to be unselected
            qtasteCheckBox.addActionListener(new ActionListener() {

                public void actionPerformed(ActionEvent e) {
                    if (!qtasteCheckBox.isSelected()) {
                        testCaseOrVerbCheckBox.setSelected(false);
                    }
View Full Code Here

            name = name.substring(NAME_SAVE_PFX_LEN);
            JCheckBox check = new JCheckBox(
                                JMeterUtils.getResString(RESOURCE_PREFIX + name)// $NON-NLS-1$
                                ,((Boolean) methods[i].invoke(saveConfig, new Object[0])).booleanValue());
            checkPanel.add(check, BorderLayout.NORTH);
            check.addActionListener(this);
                        String actionCommand = NAME_SET_PREFIX + name; // $NON-NLS-1$
            check.setActionCommand(actionCommand);
                        if (!functors.containsKey(actionCommand)) {
              functors.put(actionCommand, new Functor(actionCommand));
            }
View Full Code Here

        });
        JPanel messagePanel = new JPanel();
     
        final JCheckBox filter = new JCheckBox("Filter stack traces");
        filter.setSelected(_isFiltering);
        filter.addActionListener(new ActionListener(){
            public void actionPerformed(ActionEvent e) {
                _isFiltering = filter.isSelected();
                StringBuilder buffer = new StringBuilder();
                _stacktrace.setText(generateStackTrace(_error, buffer).toString());
                _stacktrace.repaint();
View Full Code Here


         //Create checkbox for enabling auto refresh
         // i18n[oracle.enableAutoRefresh=Enable auto refresh]
         final JCheckBox autoRefresh = new JCheckBox(s_stringMgr.getString("oracle.enableAutoRefresh"), false);
         autoRefresh.addActionListener(new ActionListener()
         {
            public void actionPerformed(ActionEvent e)
            {
               _sgaTracePanel.setAutoRefresh(autoRefresh.isSelected());
            }
View Full Code Here

                  mInitiallySelectedTypeNames, type.getName())));

          // add checkbox
          checkbox = new JCheckBox(type.getShortName(), selected);
          checkbox.setToolTipText(type.getName());
          checkbox.addActionListener(this);
          checkbox.setBackground(c);
          // annotationCheckboxPanel.add(checkbox); do it later JMP
          checkBoxes.put(type.getName(), checkbox);
          checkBoxesDone.add(checkbox);
          // add to (Type, Checkbox) map
View Full Code Here

        // assign next available color
        Color c = COLORS[mEntityToCheckboxMap.size() % COLORS.length];
        // add checkbox
        checkbox = new JCheckBox(entity.getCanonicalForm(), true);
        checkbox.setToolTipText(entity.getCanonicalForm());
        checkbox.addActionListener(this);
        checkbox.setBackground(c);
        entityCheckboxPanel.add(checkbox);
        // add to (Entity, Checkbox) map
        mEntityToCheckboxMap.put(entity, checkbox);
      }
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.