Package org.eclipse.swt.widgets

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


        }
        else
        {
            FileDialog dialog = new FileDialog(shell, SWT.NONE);
            dialog.setText(msg);
            String value = dialog.open();
            if (value != null)
            {
                text.setText(value);
            }
        }
View Full Code Here


    private void add()
    {
        Shell shell = SigilUI.getActiveWorkbenchShell();
        DirectoryDialog dialog = new DirectoryDialog(shell);
        String dir = dialog.open();
        if (dir != null)
        {
            Install install = new Install(UUID.randomUUID().toString(), dir);
            if (install.getType() == null)
            {
View Full Code Here

      public void changeControlPressed(DialogField field) {
        DirectoryDialog dialog = new DirectoryDialog(getShell());
        dialog.setFilterPath(fPathDialogField.getText());
        dialog.setText("Select the library path");
        dialog.setMessage("Please select the path which represent the PEAR library.");
        String newPath = dialog.open();
        if (newPath != null) {
          fPathDialogField.setText(newPath);
          doValidation();
        }
      }
View Full Code Here

    browse.addSelectionListener(new SelectionAdapter() {
      public void widgetSelected(SelectionEvent se) {
        DirectoryDialog dialog = new DirectoryDialog(LHttpdRuntimeComposite.this.getShell());
        dialog.setMessage(Messages.LHttpdRuntimeComposite_SelectApacheXamppInstallDir);
        dialog.setFilterPath(installDir.getText());
        String selectedDirectory = dialog.open();
        if (selectedDirectory != null)
          installDir.setText(selectedDirectory);
      }
    });
   
View Full Code Here

          return;
       
        DirectoryDialog dialog = new DirectoryDialog(LHttpdRuntimeComposite.this.getShell());
        dialog.setMessage(Messages.LHttpdRuntimeComposite_SelectXamppInstallDir);
        dialog.setFilterPath(installDir.getText());
        String selectedDirectory = dialog.open();
        if (selectedDirectory != null) {
          final IPath installPath = new Path(selectedDirectory);
          installRuntimeJob = new Job(Messages.LHttpdRuntimeComposite_TaskInstallingRuntime) {
            public boolean belongsTo(Object family) {
              return PEXServerUiPlugin.PLUGIN_ID.equals(family);
View Full Code Here

        false);
  }

  private void setUpBrowseFolderDialog() {
    DirectoryDialog directoryDialog = new DirectoryDialog(getControl().getShell());
    String folder = directoryDialog.open();
    if (folder != null && folder.length() > 0) {
      reportFolderText.setText(folder);
      setTabDirty();
    }
  }
View Full Code Here

    protected void browseForInstallDir() {
        final DirectoryDialog dialog = new DirectoryDialog(getShell());
        dialog.setFilterPath(fOtpHome.getText());
        dialog.setMessage(RuntimePreferenceMessages.addDialog_pickInstallationRoot);
        final String newPath = dialog.open();
        if (newPath != null) {
            fOtpHome.setText(newPath);
            final File f = new File(newPath);
            if (fName.getText().equals("")) {
                fName.setText(f.getName());
View Full Code Here

                        .getWorkbench().getDisplay().getActiveShell(), SWT.OPEN);
                dialog.setFilterPath(ResourcesPlugin.getWorkspace().getRoot()
                        .getLocation().toString());
                // dialog.setFilterExtensions(new String[] { "*.*" });
                dialog.setText("Load trace data...");
                final String selected = dialog.open();
                if (selected != null) {
                    task = new RunnableWithProgress("Load trace data...") {
                        @Override
                        public void doAction() {
                            TraceBackend.getInstance().loadFile(selected);
View Full Code Here

        if (lastPath != null) {
            if (new File(lastPath).exists()) {
        dialog.setFilterPath(lastPath);
      }
        }
        String dir = dialog.open();
        if (dir != null) {
            dir = dir.trim();
            if (dir.length() == 0) {
        return null;
      }
View Full Code Here

      fileDialog.setFilterPath(startingDirectory.getPath());
    }
        else if (filterPath != null) {
          fileDialog.setFilterPath(filterPath.getPath());
        }
        String dir = fileDialog.open();
        if (dir != null) {
            dir = dir.trim();
            if (dir.length() > 0) {
        return new File(dir);
      }
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.