From: lempinen Date: Tue, 16 Oct 2012 10:16:33 +0000 (+0000) Subject: Immutable resources were modified during import (refs #3785) X-Git-Tag: simantics-1.10.1~123 X-Git-Url: https://gerrit.simantics.org/r/gitweb?a=commitdiff_plain;h=07b8b1c2b67afa4a376954ea9236de2a4b3360a9;p=simantics%2Fsysdyn.git Immutable resources were modified during import (refs #3785) git-svn-id: https://www.simantics.org/svn/simantics/sysdyn/trunk@26024 ac1ea38d-2e2b-0410-8846-a27921b304fc --- diff --git a/org.simantics.sysdyn.ui/src/org/simantics/sysdyn/ui/handlers/imports/ImportModelHandler.java b/org.simantics.sysdyn.ui/src/org/simantics/sysdyn/ui/handlers/imports/ImportModelHandler.java index 024bb229..82770549 100644 --- a/org.simantics.sysdyn.ui/src/org/simantics/sysdyn/ui/handlers/imports/ImportModelHandler.java +++ b/org.simantics.sysdyn.ui/src/org/simantics/sysdyn/ui/handlers/imports/ImportModelHandler.java @@ -45,6 +45,7 @@ import org.simantics.graph.representation.TransferableGraph1; import org.simantics.issues.ontology.IssueResource; import org.simantics.layer0.Layer0; import org.simantics.layer0.utils.direct.GraphUtils; +import org.simantics.modeling.utils.BatchValidations; import org.simantics.operation.Layer0X; import org.simantics.simulation.ontology.SimulationResource; import org.simantics.structural.stubs.StructuralResource2; @@ -169,6 +170,16 @@ public class ImportModelHandler extends AbstractHandler { } }); + + + try { + BatchValidations.runAll(null, ModelRoot); + } catch(Throwable t) { + t.printStackTrace(); + } + + + } catch (DatabaseException e) { e.printStackTrace(); }