diff --git a/AlgebraicDataflowArchitectureModel/src/application/editor/Editor.java b/AlgebraicDataflowArchitectureModel/src/application/editor/Editor.java index e7c0fa2..bf9467a 100644 --- a/AlgebraicDataflowArchitectureModel/src/application/editor/Editor.java +++ b/AlgebraicDataflowArchitectureModel/src/application/editor/Editor.java @@ -202,12 +202,19 @@ Parser parser = new Parser(new BufferedReader(new FileReader(file))); try { + // Parse the .model file. model = parser.doParse(); + curFilePath = file.getAbsolutePath(); curFileName = file.getName(); + + // Analyze the model. if (!Validation.checkUpdateConflict(model)) return null; graph = constructGraph(model); analyzeDataTransferModel(model); + + // Set DAG layout. + setDAGLayout(); return model; } catch (ExpectedChannel | ExpectedChannelName | ExpectedLeftCurlyBracket | ExpectedInOrOutOrRefKeyword | ExpectedStateTransition | ExpectedEquals | ExpectedRHSExpression | WrongLHSExpression