Fix #8000 - left tree and file open
[roobuilder] / src / Builder4 / WindowLeftProps.vala
index 9966ec3..8cf971b 100644 (file)
@@ -90,7 +90,10 @@ public class Xcls_LeftProps : Object
                var file = this.file;
                var ar = file.getErrors();
                if (ar.size < 1) {
-                       this.removeErrors();
+                       if (this.last_error_counter != file.error_counter) {
+                               this.removeErrors();
+                       }
+       
                        this.last_error_counter = file.error_counter ;
        
                        return;
@@ -242,7 +245,7 @@ public class Xcls_LeftProps : Object
                var reading_header = true;
         
                while (child != null) {
-                       GLib.debug("Got %s", child.get_type().name());
+                       //GLib.debug("Got %s", child.get_type().name());
                   
                   if (reading_header) {
                                
@@ -276,39 +279,6 @@ public class Xcls_LeftProps : Object
                }
                //GLib.debug("Rturning null");
             
-       }
-       public void a_addProp (JsRender.NodeProp prop) {
-             // info includes key, val, skel, etype..
-             //console.dump(info);
-               //type = info.type.toLowerCase();
-               //var data = this.toJS();
-                 
-                     
-           if (prop.ptype == JsRender.NodePropType.LISTENER) {
-               if (this.node.listeners.has_key(prop.name)) {
-                   return;
-               }
-               this.node.listeners.set(prop.name,prop);
-           } else  {
-                assert(this.node != null);
-                assert(this.node.props != null);
-               if (this.node.props.has_key(prop.to_index_key())) {
-                   return;
-               }
-               this.node.props.set(prop.to_index_key(),prop);
-           }
-                   
-             
-           // add a row???
-           this.load(this.file, this.node);
-           
-           
-            
-           
-           GLib.debug("trying to find new iter");
-        
-           
-                     
        }
        public void load (JsRender.JsRender file, JsRender.Node? node) 
        {
@@ -1857,11 +1827,11 @@ public class Xcls_LeftProps : Object
                                                }
                                                // should be columnlistview
                                                child = child.get_first_child(); 
-                                           GLib.debug("header height=%d", h);
+                                           //GLib.debug("header height=%d", h);
                                                header_height =  h;
                                                
                                                reading_header = false;
-                                               
+                                               continue;
                                }
                                
                                    if (child.get_type().name() != "GtkColumnViewRowWidget") {
@@ -1875,6 +1845,13 @@ public class Xcls_LeftProps : Object
                                    
                                    line_no++;
                                        var hh = child.get_height();
+                                       if (child.has_css_class("node-err") || 
+                                               child.has_css_class("node-warn") || 
+                                               child.has_css_class("node-depr")) {
+                                               hh += 10;
+                                       
+                                       }
+                                       
                                        //child.get_allocation(out alloc);
                                        //GLib.debug("got cell xy = %d,%d  w,h= %d,%d", alloc.x, alloc.y, alloc.width, alloc.height);
                                        //GLib.debug("row %d y= %d %s", line_no, (int) (header_height + alloc.y),