Package org.eclipse.swt.widgets

Examples of org.eclipse.swt.widgets.MessageBox.open()


                IEditorReference[] editorReferences = page.getEditorReferences();
                if (editorReferences.length > 1) {
                  MessageBox confirmDialog = new MessageBox(page.getWorkbenchWindow().getShell(), SWT.ICON_QUESTION | SWT.YES | SWT.NO);
                  confirmDialog.setText(Messages.ApplicationActionBarAdvisor_DISABLE_TABBED_BROWSING);
                  confirmDialog.setMessage(NLS.bind(Messages.ApplicationActionBarAdvisor_TABS_MESSAGE, editorReferences.length));
                  if (confirmDialog.open() == SWT.YES)
                    OwlUI.closeOtherEditors();
                  else
                    doit = false;
                }
              }
View Full Code Here


          type = SWT.ICON_WARNING;
        }
        MessageBox messageBox = new MessageBox(shell, type | SWT.OK | (cancelText != null ? SWT.CANCEL : 0));
        messageBox.setText(title);
        messageBox.setMessage(message);
        int buttonID = messageBox.open();
        switch (buttonID) {
          case SWT.OK:
            l.add(Boolean.TRUE);
          default:
            l.add(Boolean.FALSE);
View Full Code Here

      title = "Question";
    else if ((style & SWT.ICON_WARNING) != 0)
      title = "Warning";
    mb.setText(title);

    return mb.open();
  }

  //setzt den Maus auf SandUhr
  public static void startCursor(Shell shell){
    if(!shell.isDisposed())
View Full Code Here


  public int message(String message, int style) {
    MessageBox mb = new MessageBox(_tree.getShell(), style);
    mb.setMessage(message);
    return mb.open();
  }


  private Element getElement() {
    if (_tree.getSelectionCount() > 0) { 
View Full Code Here

      title = "Question";
    else if ((style & SWT.ICON_WARNING) != 0)
      title = "Warning";
    mb.setText(title);

    return mb.open();
  }


  public static IContainer getContainer() {
    return container;
View Full Code Here


  public int message(String message, int style) {
    MessageBox mb = new MessageBox(_combo.getShell(), style);
    mb.setMessage(message);
    return mb.open();
  }


  private void createMenu() {
    _menu = new Menu(_combo.getShell(), SWT.POP_UP);
View Full Code Here

          return ;
        }
        if (listener.exists(year, month, day)) {
          MessageBox mb = new MessageBox(getShell(), SWT.ICON_INFORMATION);
          mb.setMessage(Messages.getString("date.date_exists"));
          mb.open();
          if (main != null && dom.isChanged())
            main.dataChanged();
        } else {
          listener.addDate(year, month, day);
          listener.fillList(lDates);
View Full Code Here

      if (devices == null) {
        final MessageBox dialog = new MessageBox(gui.getShell(), SWT.ICON_ERROR | SWT.OK);
        dialog.setText(config.getString("thethereal_error"));
        dialog.setMessage(config.getString("thethereal_error_long"));
        dialog.open();
        return;
      }

      for (final String device : devices) {
        final Matcher match = Pattern.compile("^([0-9]*)\\. ").matcher(device);
View Full Code Here

        getGUI().asyncExecIfNeeded(new Runnable() {
          public void run() {
            final MessageBox dialog = new MessageBox(getGUI().getShell(), SWT.ICON_ERROR | SWT.OK);
            dialog.setText(getGUI().getConfig().getString("nmap_error"));
            dialog.setMessage(getGUI().getConfig().getString("nmap_error_long"));
            dialog.open();
          }
        });

        throw ex;
      }
View Full Code Here

            MessageBox messageBox = new MessageBox( PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell(),
                SWT.OK | SWT.ICON_ERROR );
            messageBox.setText( Messages.getString( "ServerConfigurationEditor.Error" ) ); //$NON-NLS-1$
            messageBox
                .setMessage( Messages.getString( "ServerConfigurationEditor.AnErrorOccurredWhenWritingTheFileToDisk" ) + "\n" + e.getMessage() ); //$NON-NLS-1$ //$NON-NLS-2$
            messageBox.open();
            setDirty( true );
            monitor.done();
            return;
        }
    }
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.