All pastes #896552 Raw Edit

Untitled

public text v1 · immutable
#896552 ·published 2008-02-08 19:29 UTC
rendered paste body
button.addSelectionListener(new SelectionAdapter() {
  @Override public void widgetSelected(SelectionEvent evt) {
    ProgressMonitorDialog pmd = new ProgressMonitorDialog(getShell());
    try {
      pmd.run(false, false, new IRunnableWithProgress() {
        @Override public void run(IProgressMonitor monitor) {
          final Object[] ca = getElements
          getShell().getDisplay().syncExec(new Runnable() {
            @Override public void run() {
              setElements(ca);
            }
          });
        }
      });
    } catch (InvocationTargetException e) {
      Plugin.log(e);
    } catch (InterruptedException e) {
      Thread.currentThread().interrupt();
    }
  }
});