Fix #8003 - undo code
[roobuilder] / src / JsRender / NodeToJs.vala
index 008a1f4..a96ad8e 100644 (file)
@@ -46,6 +46,7 @@ public class JsRender.NodeToJs : Object {
                this.node = node;
                this.doubleStringProps = doubleStringProps;
                this.pad = pad;
+               this.node.node_pad = pad;
                
                //this.els = new Gee.ArrayList<string>(); 
                //this.ar_props = new Gee.HashMap<string,string>();
@@ -88,7 +89,12 @@ public class JsRender.NodeToJs : Object {
        public string munge ( )
        {
                //return this.mungeToString(this.node);
-
+               if (this.node.as_source_version > 0 && 
+                       this.node.as_source_version == this.node.updated_count
+                       && this.node.as_source != ""
+               ) {
+                       return this.node.as_source;
+               }
                
                this.checkChildren();
                this.readProps();
@@ -107,7 +113,11 @@ public class JsRender.NodeToJs : Object {
                //}
 
                this.mungeOut();
+               
+               this.node.as_source_version = this.node.updated_count;
+               this.node.as_source == this.ret;
                return this.ret;
+
                 
        } 
                /**