Function creates a message dialog with text
        and relevant buttons
547380
def create_message_dialog(self, text, buttons=Gtk.ButtonsType.CLOSE, icon=Gtk.MessageType.WARNING):
        
        dialog = Gtk.MessageDialog(None,
                                   Gtk.DialogFlags.DESTROY_WITH_PARENT,
                                   icon,
                                   buttons,
                                   text
        )
        return dialog
743267
public Button dialog(String message) throws IOException, UserCancelExcption {
		Map<String, Object> m = JSONProtocol.cmd("dialog");
		m.put("text", message);
		pipe.send(m);
		Map<String, Object> r = pipe.recv();
		if (!JSONProtocol.check(m, r) || !r.containsKey("button")) {
			throw new IOException("Unknown button pressed");
		}
		return Button.valueOf(((String)r.get("button")).toUpperCase());
	}
1066338
def _set_buttons(self, chat, bot):
        
        if isinstance(self.reply_markup, (
                types.ReplyInlineMarkup, types.ReplyKeyboardMarkup)):
            self._buttons = [[
                MessageButton(self._client, button, chat, bot, self.id)
                for button in row.buttons
            ] for row in self.reply_markup.rows]
            self._buttons_flat = [x for row in self._buttons for x in row]
340172
def select(message="", title="Lackey Input", options=None, default=None):
    
    if options is None or len(options) == 0:
        return ""
    if default is None:
        default = options[0]
    if default not in options:
        raise ValueError("<<default>> not in options[]")
    root = tk.Tk()
    input_text = tk.StringVar()
    input_text.set(message)
    PopupList(root, message, title, options, default, input_text)
    root.focus_force()
    root.mainloop()
    return str(input_text.get())
585336
function(title, message) {
            if (!message) {
                message = title;
                title = null;
            }

            return Dialogs.open(null, {
                "title": title,
                "message": message,
                "dialog": "confirm"
            });
        }
336475
private void createButtons() {

        addDialogClose(new Command() {

            public void execute() {

                cancelUpload();
            }
        });

        CmsPushButton cancelButton = new CmsPushButton();
        cancelButton.setTitle(org.opencms.gwt.client.Messages.get().key(org.opencms.gwt.client.Messages.GUI_CANCEL_0));
        cancelButton.setText(org.opencms.gwt.client.Messages.get().key(org.opencms.gwt.client.Messages.GUI_CANCEL_0));
        cancelButton.setSize(I_CmsButton.Size.medium);
        cancelButton.setUseMinWidth(true);
        cancelButton.addClickHandler(new ClickHandler() {

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

                cancelUpload();
            }
        });
        addButton(cancelButton);

        m_okButton = new CmsPushButton();
        m_okButton.setTitle(org.opencms.gwt.client.Messages.get().key(org.opencms.gwt.client.Messages.GUI_OK_0));
        m_okButton.setText(org.opencms.gwt.client.Messages.get().key(org.opencms.gwt.client.Messages.GUI_OK_0));
        m_okButton.setSize(I_CmsButton.Size.medium);
        m_okButton.setUseMinWidth(true);
        m_okButton.addClickHandler(new ClickHandler() {

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

                onOkClick();
            }
        });
        addButton(m_okButton);

        CmsDialogUploadButtonHandler buttonHandler = new CmsDialogUploadButtonHandler(
            new Supplier<I_CmsUploadContext>() {

                public I_CmsUploadContext get() {

                    return m_context;
                }
            });
        buttonHandler.setUploadDialog(this);
        // add a new upload button
        CmsUploadButton uploadButton = new CmsUploadButton(buttonHandler);
        uploadButton.addStyleName(I_CmsLayoutBundle.INSTANCE.uploadCss().uploadDialogButton());
        uploadButton.setText(Messages.get().key(Messages.GUI_UPLOAD_BUTTON_ADD_FILES_0));
        addButton(uploadButton);
        m_uploadButton = uploadButton;
    }
1324634
def create_dialog(self):
        """"""
        bbox = QDialogButtonBox(QDialogButtonBox.Ok | QDialogButtonBox.Cancel)
        self.idx_ok = bbox.button(QDialogButtonBox.Ok)
        self.idx_cancel = bbox.button(QDialogButtonBox.Cancel)

        filebutton = QPushButton()
        filebutton.setText('Choose')
        self.idx_filename = filebutton
        
        self.xp_format = FormMenu(['CSV', 'Brain Vision'])
        self.all_types = FormBool('All event types')
        
        self.idx_evt_type = QListWidget()
        self.idx_evt_type.setSelectionMode(QAbstractItemView.ExtendedSelection)
        
        filebutton.clicked.connect(self.save_as)
        self.all_types.connect(self.toggle_buttons)
        bbox.clicked.connect(self.button_clicked)
        
        form = QFormLayout()
        form.addRow('Filename', self.idx_filename)
        form.addRow('Format', self.xp_format)
        form.addRow(self.all_types)
        form.addRow('Event type(s)', self.idx_evt_type)
        
        btnlayout = QHBoxLayout()
        btnlayout.addStretch(1)
        btnlayout.addWidget(bbox)

        vlayout = QVBoxLayout()
        vlayout.addLayout(form)
        vlayout.addStretch(1)
        vlayout.addLayout(btnlayout)

        self.setLayout(vlayout)
895170
function ( ) {
				_createDialog ( );
				
				// The dialog is displayed
				L.popup (
					{
						keepInView : true,
						closeButton : true,
						maxWidth : 600,
						className : 'PinEditDialog'
					}
				).setContent ( _MainDiv ).setLatLng( latlng ).openOn( Map );
				document.getElementById ( 'cyPinEditDialog-TextArea' ).focus ( );
			}
29909
def display_dialog(self, *args, **kwargs):
        """"""
        form = kwargs.pop('form_instance', None)
        success_message = kwargs.pop('success_message', None)

        if not form:
            form = self.get_form_class()(initial=kwargs, instance=self.object)

        if not hasattr(form, "helper"):
            form.helper = FormHelper()
        form.helper.form_tag = False

        return {
            'title': self.title.format(
                model_name=self.get_model_config().model_name,
                object=str(self.object) if self.object else '',
            ),
            'content': self.render_to_string(self.template, {
                'form': form,
                'success_message': success_message,
            }),
            'submit_label': self.submit_label,
            'success': bool(success_message),
        }
682074
function buildDialogHtml(dialogId, dialogUnreadMessagesCount, dialogIcon, dialogName, dialogLastMessage) {
    var UnreadMessagesCountShow = '<span class="badge">' + dialogUnreadMessagesCount + '</span>',
        UnreadMessagesCountHide = '<span class="badge" style="display: none;">' + dialogUnreadMessagesCount + '</span>',
        videoCall = '<img src="images/video_call.png" class="video_state" alt="call">';

    var dialogHtml =
        '<a href="#" class="list-group-item inactive" id=' + '"' + dialogId + '"' + ' onclick="triggerDialog(' + "'" + dialogId + "'" + ')">' +
        (dialogUnreadMessagesCount ? UnreadMessagesCountShow : UnreadMessagesCountHide) +
        '<h4 class="list-group-item-heading">' + dialogIcon + '&nbsp;&nbsp;&nbsp;' +
        '<span>' + dialogName + '</span>' +
        '</h4>' + videoCall +
        '<p class="list-group-item-text last-message">' +
        (dialogLastMessage === null ? "" : dialogLastMessage) +
        '</p>' +
        '</a>';

    return dialogHtml;
}
786089
function (settings, callback) {
          if (typeof settings == "string") {
            settings = { text: settings };
          }

          settings.callback = callback;
          return MessageBox.msgBox(settings);
        }
962137
def msgbox(msg="(Your message goes here)", title=" ", ok_button="OK",image=None,root=None):
    
    if type(ok_button) != type("OK"):
        raise AssertionError("The 'ok_button' argument to msgbox must be a string.")

    return buttonbox(msg=msg, title=title, choices=[ok_button], image=image,root=root)
524430
def message(self, data):
        
        msg = gtk.MessageDialog(None, gtk.DIALOG_MODAL, gtk.MESSAGE_INFO,
                                gtk.BUTTONS_CLOSE, data)
        msg.set_resizable(1)
        msg.set_title(self.dialog_title)
        self.img.set_from_file(self.sun_icon)
        msg.set_image(self.img)
        msg.show_all()
        msg.run()
        msg.destroy()
808930
def showMessageOverlay(self, pchText, pchCaption, pchButton0Text, pchButton1Text, pchButton2Text, pchButton3Text):
        """"""

        fn = self.function_table.showMessageOverlay
        result = fn(pchText, pchCaption, pchButton0Text, pchButton1Text, pchButton2Text, pchButton3Text)
        return result
1217730
public MessageDialog build() {
        MessageDialog messageDialog = new MessageDialog(
                title,
                text,
                buttons.toArray(new MessageDialogButton[buttons.size()]));
        messageDialog.setHints(extraWindowHints);
        return messageDialog;
    }
1221940
function updateDialogsList(dialogId, text) {
    var badgeCount = $('#' + dialogId + ' .badge').html();

    // update unread message count
    $('#' + dialogId + '.list-group-item.inactive .badge').text(parseInt(badgeCount) + 1).fadeIn(500);
    // update last message
    $('#' + dialogId + ' .list-group-item-text').text(text);
}
989301
function(title, message, cb, okText) {
    cb = cb || function() {};
    $ionicPopup.alert({
      title: title,
      subTitle: message,
      okType: 'button-clear button-primary',
      okText: okText || gettextCatalog.getString('OK'),
    }).then(cb);
  }