Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/customization')
-rw-r--r--plugins/customization/org.eclipse.papyrus.customization.properties/src/org/eclipse/papyrus/customization/properties/editor/UIEditor.java28
1 files changed, 27 insertions, 1 deletions
diff --git a/plugins/customization/org.eclipse.papyrus.customization.properties/src/org/eclipse/papyrus/customization/properties/editor/UIEditor.java b/plugins/customization/org.eclipse.papyrus.customization.properties/src/org/eclipse/papyrus/customization/properties/editor/UIEditor.java
index 3e0903fba4a..8edf2aba116 100644
--- a/plugins/customization/org.eclipse.papyrus.customization.properties/src/org/eclipse/papyrus/customization/properties/editor/UIEditor.java
+++ b/plugins/customization/org.eclipse.papyrus.customization.properties/src/org/eclipse/papyrus/customization/properties/editor/UIEditor.java
@@ -261,6 +261,16 @@ public class UIEditor extends EcoreEditor implements ITabbedPropertySheetPageCon
// }
}
+ private boolean isSaving = false;
+
+ protected synchronized boolean isSaving() {
+ return isSaving;
+ }
+
+ protected synchronized void setSaving(boolean saving) {
+ this.isSaving = saving;
+ }
+
@Override
public void doSave(IProgressMonitor progressMonitor) {
if (editingDomain.getResourceToReadOnlyMap() == null) {
@@ -294,10 +304,26 @@ public class UIEditor extends EcoreEditor implements ITabbedPropertySheetPageCon
}
}
- super.doSave(progressMonitor);
+ setSaving(true);
+ try {
+ super.doSave(progressMonitor);
+ } finally {
+ setSaving(false);
+ }
refreshContext();
}
+ /**
+ * @see org.eclipse.emf.ecore.presentation.EcoreEditor#handleChangedResources()
+ *
+ */
+ @Override
+ protected void handleChangedResources() {
+ if (!isSaving()) {
+ super.handleChangedResources();
+ }
+ }
+
@Override
public void doSaveAs() {
SaveAsDialog saveAsDialog = new SaveAsDialog(getSite().getShell());

Back to the top