diff --git a/AlgebraicDataflowArchitectureModel/src/graphicalrefactor/editor/Editor.java b/AlgebraicDataflowArchitectureModel/src/graphicalrefactor/editor/Editor.java index 9683074..2aca6a3 100644 --- a/AlgebraicDataflowArchitectureModel/src/graphicalrefactor/editor/Editor.java +++ b/AlgebraicDataflowArchitectureModel/src/graphicalrefactor/editor/Editor.java @@ -165,7 +165,7 @@ try { File file = new File(curFilePath); FileWriter filewriter = new FileWriter(file); - filewriter.write(model.toString()); + filewriter.write(model.getSourceText()); filewriter.close(); } catch (IOException e) { e.printStackTrace(); @@ -430,6 +430,7 @@ } public void setChannelCode(DataflowChannelGenerator ch, String code) { + ch.setSourceText(code); TokenStream stream = new TokenStream(); for (String line: code.split("\n")) { stream.addLine(line);