Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDarin Swanson2006-01-10 14:35:11 -0500
committerDarin Swanson2006-01-10 14:35:11 -0500
commitf6f96c3e6be9c1a80bd6d3b78b69361fe9a8e6cc (patch)
treeaf07735857f6b68989eef7168f98a301bbd45d10 /org.eclipse.ui.externaltools
parente1cd44a0ee38168d30084fea2f5347e771c27ee8 (diff)
downloadeclipse.platform.debug-f6f96c3e6be9c1a80bd6d3b78b69361fe9a8e6cc.tar.gz
eclipse.platform.debug-f6f96c3e6be9c1a80bd6d3b78b69361fe9a8e6cc.tar.xz
eclipse.platform.debug-f6f96c3e6be9c1a80bd6d3b78b69361fe9a8e6cc.zip
Bug 111427 - Adding a builder with .project read-only
Diffstat (limited to 'org.eclipse.ui.externaltools')
-rw-r--r--org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/ui/BuilderPropertyPage.java23
1 files changed, 14 insertions, 9 deletions
diff --git a/org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/ui/BuilderPropertyPage.java b/org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/ui/BuilderPropertyPage.java
index ce0821913..bc6ec58c7 100644
--- a/org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/ui/BuilderPropertyPage.java
+++ b/org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/ui/BuilderPropertyPage.java
@@ -746,18 +746,22 @@ public final class BuilderPropertyPage extends PropertyPage implements ICheckSta
* Handles unexpected internal exceptions
*/
private void handleException(Exception e) {
- IStatus status;
+ final IStatus[] status= new IStatus[1];
if (e instanceof CoreException) {
- status = ((CoreException) e).getStatus();
+ status[0] = ((CoreException) e).getStatus();
} else {
- status = new Status(IStatus.ERROR, IExternalToolConstants.PLUGIN_ID, 0, ExternalToolsUIMessages.BuilderPropertyPage_statusMessage, e);
+ status[0] = new Status(IStatus.ERROR, IExternalToolConstants.PLUGIN_ID, 0, ExternalToolsUIMessages.BuilderPropertyPage_statusMessage, e);
}
- Shell shell= getShell();
- if (shell != null) {
- ErrorDialog.openError(shell, ExternalToolsUIMessages.BuilderPropertyPage_errorTitle,
- ExternalToolsUIMessages.BuilderPropertyPage_errorMessage,
- status);
- }
+ Display.getDefault().asyncExec(new Runnable() {
+ public void run() {
+ Shell shell= getShell();
+ if (shell != null) {
+ ErrorDialog.openError(shell, ExternalToolsUIMessages.BuilderPropertyPage_errorTitle,
+ ExternalToolsUIMessages.BuilderPropertyPage_errorMessage,
+ status[0]);
+ }
+ }
+ });
}
/**
@@ -998,6 +1002,7 @@ public final class BuilderPropertyPage extends PropertyPage implements ICheckSta
project.setDescription(desc, IResource.FORCE, monitor);
} catch (CoreException e) {
handleException(e);
+ performCancel();
}
}

Back to the top