This method initializes btnAccept

@return javax.swing.JButton
776043
private JButton getBtnAccept() {
		if (btnAccept == null) {
			btnAccept = new JButton();
			btnAccept.setText("Accept");
			btnAccept.addActionListener(new java.awt.event.ActionListener() {

				@Override
				public void actionPerformed(java.awt.event.ActionEvent e) {
				    accepted = true;
			        LicenseFrame.this.dispose();

				}
			});

		}
		return btnAccept;
	}
373553
@Override
	protected Button newButton(final String id)
	{
		return new Button(id)
		{
			/**
			 * The serialVersionUID.
			 */
			private static final long serialVersionUID = 1L;

			/**
			 * {@inheritDoc}
			 */
			@Override
			public void onSubmit()
			{
				getAction().execute();
			}
		};
	}
999893
@UiChild(tagname="backButton", limit=1)
    public void setBackButton(JQMButton button) {
        button.setBack(true);
        setLeftButton(button);
    }
358721
private JButton getBtnOK() {
        if (btnOK == null) {
            btnOK = new JButton();
            btnOK.setName("btnOK");
            btnOK.setText(Constant.messages.getString("all.button.ok"));
            btnOK.addActionListener(new ActionListener() {
                @Override
                public void actionPerformed(ActionEvent e) {

                    try {
                        validateParam();
                        saveParam();
                        exitResult = JOptionPane.OK_OPTION;

                        AbstractParamDialog.this.setVisible(false);

                    } catch (NullPointerException ex) {
                        LOGGER.error("Failed to validate or save the panels: ", ex);
                        showSaveErrorDialog(ex.getMessage());
                    } catch (Exception ex) {
                        if (LOGGER.isDebugEnabled()) {
                            LOGGER.debug("Failed to validate or save the panels: ", ex);
                        }
                        showSaveErrorDialog(ex.getMessage());
                    }
                }
            });

        }
        return btnOK;
    }
423942
protected JButton createRightOneTouchButton() {
        SeaGlassArrowButton b            = new SeaGlassArrowButton(SwingConstants.NORTH);
        int                 oneTouchSize = lookupOneTouchSize();

        b.setName("SplitPaneDivider.rightOneTouchButton");
        b.setMinimumSize(new Dimension(oneTouchSize, oneTouchSize));
        // Rossi: Change cursors on "one touch" buttons. Better would be an mouse over effect
        b.setCursor(Cursor.getPredefinedCursor(
            splitPane.getOrientation() == 
                JSplitPane.HORIZONTAL_SPLIT ? 
                        Cursor.E_RESIZE_CURSOR:Cursor.S_RESIZE_CURSOR));
        b.setFocusPainted(false);
        b.setBorderPainted(false);
        b.setRequestFocusEnabled(false);
        b.setDirection(mapDirection(false));

        return b;
    }
850034
@SuppressWarnings("unchecked")
    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
    private void initComponents() {

        colorChooser = new javax.swing.JColorChooser();
        okButton = new javax.swing.JButton();
        cancelButton = new javax.swing.JButton();

        setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);

        okButton.setText("OK");
        okButton.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                okButtonActionPerformed(evt);
            }
        });

        cancelButton.setText("Cancel");
        cancelButton.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                cancelButtonActionPerformed(evt);
            }
        });

        javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
        getContentPane().setLayout(layout);
        layout.setHorizontalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(layout.createSequentialGroup()
                .addContainerGap()
                .addComponent(colorChooser, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
            .addGroup(layout.createSequentialGroup()
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                .addComponent(cancelButton, javax.swing.GroupLayout.PREFERRED_SIZE, 96, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(okButton, javax.swing.GroupLayout.PREFERRED_SIZE, 106, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addContainerGap())
        );
        layout.setVerticalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(layout.createSequentialGroup()
                .addContainerGap()
                .addComponent(colorChooser, javax.swing.GroupLayout.PREFERRED_SIZE, 370, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(cancelButton)
                    .addComponent(okButton))
                .addContainerGap())
        );

        pack();
    }
1011781
private void iniButtons() {

        m_newButton = CmsToolBar.createButton(
            FontOpenCms.WAND,
            CmsVaadinUtils.getMessageText(Messages.GUI_USERMANAGEMENT_ADD_ELEMENT_0));
        m_newButton.addClickListener(new ClickListener() {

            private static final long serialVersionUID = 1L;

            public void buttonClick(ClickEvent event) {

                openNewDialog();
            }
        });
        m_infoButton = new CmsInfoButton();
        Button csvButton = new Button(CmsVaadinUtils.getMessageText(Messages.GUI_USERMANAGEMENT_EXPORT_ONLY_USER_0));
        csvButton.addClickListener(new ClickListener() {

            private static final long serialVersionUID = 5472430305539438757L;

            public void buttonClick(ClickEvent event) {

                boolean includeTechnicalFields = false;
                try {
                    OpenCms.getRoleManager().checkRole(m_cms, CmsRole.ADMINISTRATOR);
                    includeTechnicalFields = true;
                } catch (CmsRoleViolationException e) {
                    // ok
                }
                Window window = CmsBasicDialog.prepareWindow(DialogWidth.wide);
                CmsUserCsvExportDialog dialog = new CmsUserCsvExportDialog(
                    getFullUser(getVisibleUser()),
                    m_stateBean.getPath(),
                    m_stateBean.getType(),
                    getElementName(m_stateBean),
                    CmsVaadinUtils.isButtonPressed(getToggleButton(m_stateBean)),
                    window,
                    includeTechnicalFields);
                window.setContent(dialog);
                A_CmsUI.get().addWindow(window);

            }

        });
        m_infoButton.setAdditionalButton(csvButton);

        m_addElementButton = CmsToolBar.createButton(
            FontAwesome.PLUS,
            CmsVaadinUtils.getMessageText(Messages.GUI_USERMANAGEMENT_ADD_USER_TO_GROUP_0));
        m_addElementButton.addClickListener(new ClickListener() {

            private static final long serialVersionUID = 1859694635385726953L;

            public void buttonClick(ClickEvent event) {

                openAddUserDialog();

            }
        });

        m_toggleButtonRole = CmsToolBar.createButton(
            FontOpenCms.USERS,
            CmsVaadinUtils.getMessageText(Messages.GUI_USERMANAGEMENT_ROLES_TOGGLE_0));
        m_toggleButtonRole.addClickListener(new ClickListener() {

            private static final long serialVersionUID = 8265075332953321274L;

            public void buttonClick(ClickEvent event) {

                toggleTable(m_toggleButtonRole);

            }

        });

        m_toggleButtonUser = CmsToolBar.createButton(
            FontOpenCms.USERS,
            CmsVaadinUtils.getMessageText(Messages.GUI_USERMANAGEMENT_USER_TOGGLE_0));
        m_toggleButtonUser.addClickListener(new ClickListener() {

            private static final long serialVersionUID = 8265075332953321274L;

            public void buttonClick(ClickEvent event) {

                toggleTable(m_toggleButtonUser);

            }

        });

        m_toggleButtonGroups = CmsToolBar.createButton(
            FontOpenCms.USERS,
            CmsVaadinUtils.getMessageText(Messages.GUI_USERMANAGEMENT_GROUPS_TOGGLE_0));
        m_toggleButtonGroups.addClickListener(new ClickListener() {

            private static final long serialVersionUID = 8265075332953321274L;

            public void buttonClick(ClickEvent event) {

                toggleTable(m_toggleButtonGroups);

            }

        });

        m_uiContext.addToolbarButton(m_newButton);

        m_uiContext.addToolbarButton(m_addElementButton);
        m_uiContext.addToolbarButton(m_infoButton);
        m_uiContext.addToolbarButton(m_toggleButtonRole);
        m_uiContext.addToolbarButton(m_toggleButtonUser);
        m_uiContext.addToolbarButton(m_toggleButtonGroups);

        for (Button button : getAdditionalButtons()) {
            m_uiContext.addToolbarButton(button);
        }
        m_filter = CmsVaadinUtils.getOUComboBox(m_cms, m_baseOU, LOG);
        m_filter.setWidth("379px");
        m_infoLayout.addComponent(m_filter, 0);

        m_filterTable = new TextField();
        m_filterTable.setIcon(FontOpenCms.FILTER);
        m_filterTable.setInputPrompt(
            Messages.get().getBundle(UI.getCurrent().getLocale()).key(Messages.GUI_EXPLORER_FILTER_0));
        m_filterTable.addStyleName(ValoTheme.TEXTFIELD_INLINE_ICON);
        //            m_filterTable.setWidth("200px");
        m_filterTable.addTextChangeListener(new TextChangeListener() {

            private static final long serialVersionUID = 1L;

            public void textChange(TextChangeEvent event) {

                filterTable(event.getText());
            }
        });
        m_filterTable.setWidth("200px");
        m_infoLayout.addComponent(m_filterTable);
        m_infoLayout.addStyleName("o-many-elements");
        m_filter.addValueChangeListener(new ValueChangeListener() {

            private static final long serialVersionUID = 1L;

            public void valueChange(ValueChangeEvent event) {

                if ((m_stateBean.getType() != null) & !m_doNotChange) {
                    update((String)event.getProperty().getValue(), CmsOuTreeType.OU, null);
                } else {
                    //
                }
            }
        });
        if (!m_ouHandler.isOUManagable(m_stateBean.getPath())) {
            boolean change = m_doNotChange;
            m_doNotChange = false;
            m_filter.select(m_filter.getItemIds().iterator().next());
            m_doNotChange = change;
        }
    }
1214718
private CmsPushButton createCancelButton() {

        addDialogClose(null);
        CmsPushButton button = new CmsPushButton();
        button.setText(Messages.get().key(Messages.GUI_CANCEL_0));
        button.setUseMinWidth(true);
        button.addClickHandler(new ClickHandler() {

            /**
             * @see com.google.gwt.event.dom.client.ClickHandler#onClick(com.google.gwt.event.dom.client.ClickEvent)
             */
            public void onClick(ClickEvent event) {

                CmsSeoOptionsDialog.this.hide();
            }
        });

        return button;
    }
237465
private void jButton2ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jButton2ActionPerformed

        JavaProcessBuilder pb = SAMPLE_QUEUE.newProcessBuilder(Locale.getDefault());
        pb.setProcessName("Test 2");
        pb.setProcessPersistence(false);

        for (int i = 0; i<=(Integer)jSpinner1.getValue(); i++) {
            pb.setProcessDescription("Test 2");
            pb.setProcessDetails(new TestRunner(), "run", new Class[] {}, new Object[] {});

            RunOnce occurrence = new RunOnce();
            RelativeScheduleBuilder rsb = occurrence.newRelativeScheduleBuilder();
            rsb.setRunDelaySeconds((int)(Math.random() * 60));
            rsb.createSchedule();
            pb.setProcessOccurrence(occurrence);

            pb.newProcess();
        }
    }
548435
public InputListener getDefaultInputListener (final int mouseButton) {
		if (defaultInputListener == null) {
			defaultInputListener = new InputListener() {
				@Override
				public boolean touchDown (InputEvent event, float x, float y, int pointer, int button) {
					return true;
				}

				@Override
				public void touchUp (InputEvent event, float x, float y, int pointer, int button) {
					if (event.getButton() == mouseButton)
						showMenu(event.getStage(), event.getStageX(), event.getStageY());
				}
			};
		}

		return defaultInputListener;
	}
431522
private JButton getOkButton()
    {
        if (okButton == null)
        {
            okButton = new JButton();
            okButton.setText("Go!");
            okButton.addActionListener(new java.awt.event.ActionListener()
            {
                public void actionPerformed(java.awt.event.ActionEvent e)
                {
                    displayURL(urlText.getText());
                }
            });
        }
        return okButton;
    }
590473
private void initButtons() {

        m_addButton.addChoice(
            m_attributeHandler.getWidgetService(),
            new CmsChoiceMenuEntryBean(m_attributeHandler.getAttributeName()),
            new AsyncCallback<CmsChoiceMenuEntryBean>() {

                public void onFailure(Throwable caught) {

                    // will not be called

                }

                public void onSuccess(CmsChoiceMenuEntryBean selectedEntry) {

                    // nothing to do
                }
            });
        m_addButton.addDomHandler(new ClickHandler() {

            public void onClick(ClickEvent event) {

                m_addButton.hide();
                addNewAttributeValue();
                event.preventDefault();
                event.stopPropagation();

            }
        }, ClickEvent.getType());

        m_editButton.setImageClass(I_CmsButton.PEN_SMALL);
        m_editButton.setButtonStyle(ButtonStyle.FONT_ICON, null);

        m_removeButton.setImageClass(I_CmsButton.CUT_SMALL);
        m_removeButton.setButtonStyle(ButtonStyle.FONT_ICON, null);

        m_upButton.setImageClass(I_CmsButton.EDIT_UP_SMALL);
        m_upButton.setButtonStyle(ButtonStyle.FONT_ICON, null);

        m_downButton.setImageClass(I_CmsButton.EDIT_DOWN_SMALL);
        m_downButton.setButtonStyle(ButtonStyle.FONT_ICON, null);

        if (CmsEditorBase.hasDictionary()) {
            String label = m_widgetService.getAttributeLabel(m_attributeHandler.getAttributeName());
            m_addButton.setTitle(CmsEditorBase.getMessageForKey(CmsEditorBase.GUI_VIEW_ADD_1, label));
            m_removeButton.setTitle(CmsEditorBase.getMessageForKey(CmsEditorBase.GUI_VIEW_DELETE_1, label));
            m_upButton.setTitle(CmsEditorBase.getMessageForKey(CmsEditorBase.GUI_VIEW_MOVE_UP_0));
            m_downButton.setTitle(CmsEditorBase.getMessageForKey(CmsEditorBase.GUI_VIEW_MOVE_DOWN_0));
            m_title = CmsEditorBase.getMessageForKey(CmsEditorBase.GUI_VIEW_EDIT_1, label);
            m_editButton.setTitle(m_title);
        }
    }
787007
@SuppressWarnings ("unchecked")
  // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
  private void initComponents() {

    jScrollPane1 = new javax.swing.JScrollPane();
    tableKeyShortcuts = new javax.swing.JTable();
    jPanel1 = new javax.swing.JPanel();
    labelKeyCode = new javax.swing.JLabel();
    checkBoxALT = new javax.swing.JCheckBox();
    checkBoxCTRL = new javax.swing.JCheckBox();
    checkBoxSHIFT = new javax.swing.JCheckBox();
    checkBoxMeta = new javax.swing.JCheckBox();
    textFieldKeyCode = new javax.swing.JTextField();
    buttonEditKeyCode = new javax.swing.JToggleButton();

    setLayout(new java.awt.BorderLayout());

    java.util.ResourceBundle bundle = java.util.ResourceBundle.getBundle("com/igormaznitsa/nbmindmap/i18n/Bundle"); // NOI18N
    jScrollPane1.setBorder(javax.swing.BorderFactory.createTitledBorder(bundle.getString("KeyShortCutEditPanel.ScrollPaneBorderTitle"))); // NOI18N

    tableKeyShortcuts.setSelectionMode(javax.swing.ListSelectionModel.SINGLE_SELECTION);
    tableKeyShortcuts.addMouseListener(new java.awt.event.MouseAdapter() {
      public void mouseClicked(java.awt.event.MouseEvent evt) {
        tableKeyShortcutsMouseClicked(evt);
      }
    });
    jScrollPane1.setViewportView(tableKeyShortcuts);

    add(jScrollPane1, java.awt.BorderLayout.CENTER);

    org.openide.awt.Mnemonics.setLocalizedText(labelKeyCode, bundle.getString("KeyShortCutEditPanel.labelKeyCode.text")); // NOI18N

    org.openide.awt.Mnemonics.setLocalizedText(checkBoxALT, bundle.getString("KeyShortCutEditPanel.checkBoxALT.text")); // NOI18N

    org.openide.awt.Mnemonics.setLocalizedText(checkBoxCTRL, bundle.getString("KeyShortCutEditPanel.checkBoxCTRL.text")); // NOI18N

    org.openide.awt.Mnemonics.setLocalizedText(checkBoxSHIFT, bundle.getString("KeyShortCutEditPanel.checkBoxSHIFT.text")); // NOI18N

    org.openide.awt.Mnemonics.setLocalizedText(checkBoxMeta, bundle.getString("KeyShortCutEditPanel.checkBoxMeta.text")); // NOI18N

    textFieldKeyCode.addFocusListener(new java.awt.event.FocusAdapter() {
      public void focusLost(java.awt.event.FocusEvent evt) {
        textFieldKeyCodeFocusLost(evt);
      }
    });
    textFieldKeyCode.addKeyListener(new java.awt.event.KeyAdapter() {
      public void keyTyped(java.awt.event.KeyEvent evt) {
        textFieldKeyCodeKeyTyped(evt);
      }
      public void keyPressed(java.awt.event.KeyEvent evt) {
        textFieldKeyCodeKeyPressed(evt);
      }
    });

    org.openide.awt.Mnemonics.setLocalizedText(buttonEditKeyCode, bundle.getString("KeyShortCutEditPanel.buttonEditKeyCode.text")); // NOI18N
    buttonEditKeyCode.addActionListener(new java.awt.event.ActionListener() {
      public void actionPerformed(java.awt.event.ActionEvent evt) {
        buttonEditKeyCodeActionPerformed(evt);
      }
    });

    javax.swing.GroupLayout jPanel1Layout = new javax.swing.GroupLayout(jPanel1);
    jPanel1.setLayout(jPanel1Layout);
    jPanel1Layout.setHorizontalGroup(
      jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
      .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel1Layout.createSequentialGroup()
        .addContainerGap(44, Short.MAX_VALUE)
        .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
          .addGroup(jPanel1Layout.createSequentialGroup()
            .addComponent(labelKeyCode)
            .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
            .addComponent(textFieldKeyCode))
          .addGroup(jPanel1Layout.createSequentialGroup()
            .addComponent(checkBoxALT)
            .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
            .addComponent(checkBoxCTRL)
            .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
            .addComponent(checkBoxSHIFT)
            .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
            .addComponent(checkBoxMeta)))
        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
        .addComponent(buttonEditKeyCode)
        .addContainerGap())
    );
    jPanel1Layout.setVerticalGroup(
      jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
      .addGroup(jPanel1Layout.createSequentialGroup()
        .addContainerGap()
        .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
          .addComponent(buttonEditKeyCode, javax.swing.GroupLayout.PREFERRED_SIZE, 56, javax.swing.GroupLayout.PREFERRED_SIZE)
          .addGroup(javax.swing.GroupLayout.Alignment.LEADING, jPanel1Layout.createSequentialGroup()
            .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
              .addComponent(labelKeyCode)
              .addComponent(textFieldKeyCode, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
            .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
            .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
              .addComponent(checkBoxALT)
              .addComponent(checkBoxCTRL)
              .addComponent(checkBoxSHIFT)
              .addComponent(checkBoxMeta))))
        .addContainerGap(44, Short.MAX_VALUE))
    );

    add(jPanel1, java.awt.BorderLayout.PAGE_END);
  }
216196
private JButton getBtnOK() {
		if (btnOK == null) {
			btnOK = new JButton();
			btnOK.setText(Constant.messages.getString("all.button.ok"));
			btnOK.addActionListener(new java.awt.event.ActionListener() { 

				@Override
				public void actionPerformed(java.awt.event.ActionEvent e) {    
					saveAndClose();
				}
			});

		}
		return btnOK;
	}
1276982
protected JComponent createButtonBar() {
		this.dialogCommandGroup = getCommandManager().createCommandGroup(null, getCommandGroupMembers());
		JComponent buttonBar = this.dialogCommandGroup.createButtonBar();
		GuiStandardUtils.attachDialogBorder(buttonBar);
		return buttonBar;
	}
1174530
private JButton getBtnReset() {
		if (btnReset == null) {
			btnReset = new JButton();
			btnReset.setText(Constant.messages.getString("history.filter.button.clear"));
			btnReset.addActionListener(new java.awt.event.ActionListener() { 

				@Override
				public void actionPerformed(java.awt.event.ActionEvent e) {    

					exitResult = JOptionPane.NO_OPTION;
					// Unset everything
					methodList.setSelectedIndices(new int[0]);
					codeList.setSelectedIndices(new int[0]);
					tagList.setSelectedIndices(new int[0]);
					riskList.setSelectedIndices(new int[0]);
					confidenceList.setSelectedIndices(new int[0]);
					notesComboBox.setSelectedItem(HistoryFilter.NOTES_IGNORE);
					regexInc.setText("");
					regexExc.setText("");
					filter.reset();
				}
			});

		}
		return btnReset;
	}
750819
public static synchronized void setToggling (AbstractButton b)
    {
        if (_toggler == null) {
            _toggler = new ActionListener () {
                public void actionPerformed (ActionEvent event)
                {
                    AbstractButton but = (AbstractButton) event.getSource();
                    but.setSelected(!but.isSelected());
                }
            };
        }

        b.addActionListener(_toggler);
    }