Skip to content

Commit ccafe58

Browse files
committed
Fix ProgressManager.run(boolean, boolean, IRunnableWithProgress)
Fixed regression from ccd8bab Fixes eclipse-pde/eclipse.pde#1971
1 parent 2aec138 commit ccafe58

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

bundles/org.eclipse.ui.workbench/eclipseui/org/eclipse/ui/internal/progress/ProgressManager.java

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -967,10 +967,13 @@ public void showInDialog(Shell shell, Job job) {
967967
@Override
968968
public void run(boolean fork, boolean cancelable, IRunnableWithProgress runnable)
969969
throws InvocationTargetException, InterruptedException {
970-
if (!shouldRunInBackground() && (!fork || !cancelable)) {
970+
if (!fork || !cancelable) {
971971
// Backward compatible code.
972972
final ProgressMonitorJobsDialog dialog = new ProgressMonitorJobsDialog(
973973
ProgressManagerUtil.getDefaultParent());
974+
if (shouldRunInBackground()) {
975+
dialog.setOpenOnRun(false);
976+
}
974977
dialog.run(fork, cancelable, runnable);
975978
return;
976979
}

0 commit comments

Comments
 (0)