update version number when sending temporary change from node
authorAlan Knowles <alan@roojs.com>
Sat, 20 Jan 2024 17:11:07 +0000 (01:11 +0800)
committerAlan Knowles <alan@roojs.com>
Sat, 20 Jan 2024 17:11:07 +0000 (01:11 +0800)
src/Builder4/Editor.bjs
src/Builder4/Editor.vala
src/JsRender/NodeProp.vala
src/Palete/LanguageClientJavascript.vala

index b1a00f9..16e7df7 100644 (file)
           "\tvar oldcode  = _this.prop.val;",
           "\t",
           "\t_this.prop.val = str;",
+          "\t_this.node.updated_count++;",
           "    _this.file.getLanguageServer().document_change(_this.file);",
+          "    _this.node.updated_count++;",
           "    _this.prop.val = oldcode;",
           "    ",
           "    ",
index 845175e..2b47e91 100644 (file)
@@ -885,7 +885,9 @@ public class Editor : Object
                        var oldcode  = _this.prop.val;
                        
                        _this.prop.val = str;
+                       _this.node.updated_count++;
                    _this.file.getLanguageServer().document_change(_this.file);
+                   _this.node.updated_count++;
                    _this.prop.val = oldcode;
                    
                    
index 9350212..1cf7d32 100644 (file)
@@ -215,6 +215,7 @@ public class JsRender.NodeProp : Object {
                this.rtype = rtype;
                this.val = val;
                this.childstore = new GLib.ListStore( typeof(NodeProp));
+                
        }
        
        
index 87303aa..19371a4 100644 (file)
@@ -16,18 +16,7 @@ namespace Palete {
                public override void startServer()
                {
                }
-               string generateTempContents(JsRender.JsRender file, JsRender.NodeProp? prop, string alt_code) {
-               
-                       var oldcode  = "";
-                       var contents = alt_code;
-                       if (prop != null) {
-                               oldcode  = prop.val;
-                               prop.val = alt_code;
-                               contents = file.toSourceCode();
-                               prop.val = oldcode;
-                       }
-                       return contents;
-               }
+