src/Builder4/ValaCompileResults.bjs
authorAlan Knowles <alan@roojs.com>
Thu, 28 May 2015 08:49:31 +0000 (16:49 +0800)
committerAlan Knowles <alan@roojs.com>
Thu, 28 May 2015 08:49:31 +0000 (16:49 +0800)
src/Builder4/ValaCompileResults.vala

src/Builder4/ValaCompileResults.bjs
src/Builder4/ValaCompileResults.vala

index 66f9bc5..0030d29 100644 (file)
@@ -10,7 +10,7 @@
   {
    "int height_request" : 400,
    "id" : "ValaCompileResults",
-   "| void show" : "( Gtk.Widget onbtn, bool reset) {\n\tthis.window.el.get_size(out w, out h);\n    \n    // left tree = 250, editor area = 500?\n    \n    var new_w = int.min(500, w-100);\n    if (new_w > (w-100)) {\n        new_w = w-100;\n    }\n    this.el.set_size_request( int.max(100, new_w), int.max(100, h-120));\n \n\n    if (this.el.relative_to == null) {\n        this.el.set_relative_to(onbtn);\n    }\n    this.el.show_all();\n   // not sure why..\n   \n   \n   \n    while(Gtk.events_pending()) { \n            Gtk.main_iteration();\n    }\n    if (reset) {\n\t\tvar buf = (Gtk.SourceBuffer)this.sourceview.el.get_buffer();\n\t\tbuf.set_text(\"\",0);\n\t}\n    \n    \n}\n",
+   "| void show" : "( Gtk.Widget onbtn, bool reset) {\n\tthis.window.el.get_size(out w, out h);\n    \n    // left tree = 250, editor area = 500?\n    \n    var new_w = int.min(500, w-100);\n    if (new_w > (w-100)) {\n        new_w = w-100;\n    }\n    this.el.set_size_request( int.max(100, new_w), int.max(100, h-120));\n \n\n    if (this.el.relative_to == null) {\n        this.el.set_relative_to(onbtn);\n    }\n    this.el.show_all();\n   // not sure why..\n   \n   if (reset) {\n\t\tvar buf = (Gtk.SourceBuffer)this.sourceview.el.get_buffer();\n\t\tbuf.set_text(\"\",0);\n\t}\n   \n    while(Gtk.events_pending()) { \n            Gtk.main_iteration();\n    }\n    \n    \n    \n}\n",
    "Xcls_MainWindow window" : "",
    "xtype" : "Popover",
    "Gtk.PositionType position" : "Gtk.PositionType.TOP",
index 1291300..004deb5 100644 (file)
@@ -57,15 +57,15 @@ public class Xcls_ValaCompileResults : Object
         this.el.show_all();
        // not sure why..
        
-       
+       if (reset) {
+               var buf = (Gtk.SourceBuffer)this.sourceview.el.get_buffer();
+               buf.set_text("",0);
+       }
        
         while(Gtk.events_pending()) { 
                 Gtk.main_iteration();
         }
-        if (reset) {
-               var buf = (Gtk.SourceBuffer)this.sourceview.el.get_buffer();
-               buf.set_text("",0);
-       }
+        
         
         
     }