Method invoked when OK button is clicked.
358568
def accept(self):
        """"""

        self.save_state()
        self.dock.show_busy()

        # The order of the components are matter.
        components = self.prepare_components()
        error_code, message = self.impact_function.generate_report(
            components, iface=self.iface)

        if error_code == ImpactReport.REPORT_GENERATION_FAILED:
            self.dock.hide_busy()
            LOGGER.info(tr(
                'The impact report could not be generated.'))
            send_error_message(self, message)
            LOGGER.info(message.to_text())
            return ANALYSIS_FAILED_BAD_CODE, message

        sender_name = self.sender().objectName()

        try:
            if sender_name == 'button_print_pdf':
                self.create_pdf = True
                self.open_as_pdf()
            else:
                self.create_pdf = False
                self.open_in_composer()
            self.dock.hide_busy()
        except Exception:
            self.dock.hide_busy()

        QtWidgets.QDialog.accept(self)
879597
void onRendererSelected() {
        if (view.getRendererSelected() != null) {
            rendererLibrary = rendererManager.getRendererByName(view.getRendererSelected());
            selectCommand.execute();
        }
    }
772178
public void onClick(MenuItemClickEvent event) {
		if (editController.getEditMode() == EditMode.DRAG_MODE) {
			editController.setEditMode(EditMode.INSERT_MODE);
		} else {
			editController.setEditMode(EditMode.DRAG_MODE);
		}
	}
234897
function () {

            var aButtons = this.cfg.getProperty("buttons"),
                oButton,
                oElement;

            if (aButtons && Lang.isArray(aButtons)) {
                oButton = aButtons[0];
                if (oButton) {
                    oElement = this._getButton(oButton.htmlButton);
                    if (oElement) {
                        /*
                            Place the call to the "focus" method inside a 
                            try/catch block to prevent IE from throwing 
                            JavaScript errors if the element is disabled 
                            or hidden.
                        */
                        try {
                            oElement.focus();
                        } catch(oException) {
                            // ignore
                        }
                    }
                }
            }
        }
441131
def OnButtonCell(self, event):
        """"""

        # The button text
        text = event.text

        with undo.group(_("Button")):
            self.grid.actions.set_attr("button_cell", text)

        self.grid.ForceRefresh()

        self.grid.update_attribute_toolbar()

        event.Skip()
852268
void onButtonFired(final ActionEvent event) {

        final Optional<Button> b = getTarget(event, Button.class);

        final Optional<UniqueKey<? extends Model>> data = getUserData(b, StackWaves.PAGE_MODEL_KEY);

        if (data.isPresent()) {
            model().sendWave(StackWaves.SHOW_PAGE_MODEL,
                             WBuilder.waveData(StackWaves.PAGE_MODEL_KEY, data.get()),
                             WBuilder.waveData(StackWaves.STACK_NAME, "DemoStack"));

        }
    }
695980
def _on_click(self):
        """"""
        if callable(self.__callback):
            self.__callback((self.bold, self.italic, self.underline, self.overstrike))
165407
@Override
    public void onPositiveButtonClicked(int requestCode) {
        if (requestCode == REQUEST_SIMPLE_DIALOG) {
            Toast.makeText(c, "Positive button clicked", Toast.LENGTH_SHORT).show();
        }
    }
217096
@OnClick(R.id.iv_photo) void onPhotoClicked() {
    Toast.makeText(getActivity(), placeViewModel.getName(), Toast.LENGTH_LONG).show();
  }
1047888
def OnButtonCell(self, event):
        """"""

        if self.button_cell_button_id == event.GetId():
            if event.IsChecked():
                label = self._get_button_label()
                post_command_event(self, self.ButtonCellMsg, text=label)
            else:
                post_command_event(self, self.ButtonCellMsg, text=False)

        event.Skip()
584085
def on_click(self, handler):
        ''' 

        '''
        self.on_event(ButtonClick, handler)
        self.on_event(MenuItemClick, handler)
198535
def on_mode_button(self, my_button, state):
        """"""
        if state:
            # The new mode is the label of the button
            self.controller.set_mode(my_button.get_label())
170910
public void actionPerformed(ActionEvent ae) {

		Object source = ae.getSource();

		if (source == cancel_button)
			onCancel();
		else if (source == add_button || source == direct_text)
			onAdd();
		else if (source == remove_button)
			onRemove();
		else if (source == dismiss_button)
			onDismiss();
		else if (source == ok_button || source instanceof TextField)
			onOK();
	}
904007
public void buttonClick(View v) {
        switch (v.getId()) {
            case R.id.show:
                showAppMsg();
                break;
            case R.id.cancel_all:
                AppMsg.cancelAll(this);
                break;
            default:
                return;
        }
    }
446522
private void okButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_okButtonActionPerformed
        // Exit dialogue and send content to main window
        OkapiUI.dataInputField.setText(dataInputArea.getText());
        dispose();
    }
349640
public void actionPerformed(ActionEvent e) {
        if (foxml11Button.isSelected()) {
            fmt_chosen = FOXML1_1.uri;
        } else if (foxml10Button.isSelected()) {
            fmt_chosen = FOXML1_0.uri;
        } else if (mets11Button.isSelected()) {
            fmt_chosen = METS_EXT1_1.uri;
        } else if (mets10Button.isSelected()) {
            fmt_chosen = METS_EXT1_0.uri;
        } else if (atomButton.isSelected()) {
            fmt_chosen = ATOM1_1.uri;
        } else if (atomZipButton.isSelected()) {
            fmt_chosen = ATOM_ZIP1_1.uri;
        }
    }
338637
public void onClick(ClickEvent event) {
		GwtCommandDispatcher dispatcher = GwtCommandDispatcher.getInstance();
		SsecAccess.logout();
		dispatcher.logout();
	}