resources/Editors/Editor.Roo.grid.Grid.bjs
[app.Builder.js] / src / Builder4 / WindowState.vala
index 984a05f..359677b 100644 (file)
@@ -38,36 +38,44 @@ public class WindowState : Object
     public Xcls_ClutterFiles     clutterfiles;
 
     public Xcls_WindowLeftProjects left_projects; // can not see where this is initialized.. 
+    
+    public DialogTemplateSelect template_select; 
+    
+    // dialogs??
+    public Xcls_DialogPluginWebkit webkit_plugin;
+    
     // ctor 
     public WindowState(Xcls_MainWindow win)
     {
-        this.win = win;
-        // initialize
-
-        // left elements..
-        this.leftTreeInit();
-        this.propsListInit();
-
-        // on clutter space...
-        this.projectEditInit();
-        this.codeEditInit();
-        this.projectListInit();
-        this.fileViewInit();
-        
-        // adding stuff
-        this.objectAddInit();
-        this.propsAddInit();
-     
-        
-        // previews...
-        this.gtkViewInit();
-        this.webkitViewInit();
+               this.win = win;
+               // initialize
 
-        // dialogs
+               // left elements..
+               this.leftTreeInit();
+               this.propsListInit();
 
-        this.fileNewInit();
+               // on clutter space...
+               this.projectEditInit();
+               this.codeEditInit();
+               this.projectListInit();
+               this.fileViewInit();
 
-        this.children_loaded = true;
+               // adding stuff
+               this.objectAddInit();
+               this.propsAddInit();
+
+
+               // previews...
+               this.gtkViewInit();
+               this.webkitViewInit();
+
+               // dialogs
+
+               this.fileNewInit();
+
+               this.webkit_plugin = new Xcls_DialogPluginWebkit();
+               this.template_select = new DialogTemplateSelect();
+               this.children_loaded = true;
     }
 
 
@@ -502,6 +510,9 @@ public class WindowState : Object
                  break;
 
            case State.PROJECT:
+                if (this.win.project.xtype == "Gtk") {
+                    this.vala_projectsettings.save();
+                } 
                 
                 this.win.projecteditview.el.set_scale(0.0f,0.0f);
                  break;
@@ -629,7 +640,7 @@ public class WindowState : Object
 
            case State.PROJECT:
 
-             if (this.win.project.xtype == "Roo") {
+               if (this.win.project.xtype == "Roo") {
                     this.projectsettings.el.show_all();
                     this.projectsettings.show(this.win.project);
                 } else {
@@ -751,7 +762,8 @@ public class WindowState : Object
                 this.win.projecteditview.el.set_size(alloc.width-50, alloc.height / 2.0f);
                
                // this.win.rooview.el.save_easing_state();
-                this.win.rooview.el.set_size(alloc.width / 2.0f, alloc.height / 2.0f);
+                //this.win.rooview.el.set_size(alloc.width / 2.0f, alloc.height / 2.0f);
+                this.win.rooview.el.set_scale(0.5f, 0.5f);
                 //this.win.rooview.el.restore_easing_state();
                 break;
 
@@ -804,7 +816,7 @@ public class WindowState : Object
         this.win.addfilebutton.el.hide();
         this.win.delprojectbutton.el.hide();
         this.win.new_window.el.hide();
-
+        this.win.reload_resources.el.hide();
         
         switch (this.state) {
             
@@ -845,6 +857,7 @@ public class WindowState : Object
                 this.win.addfilebutton.el.show();
                 this.win.delprojectbutton.el.show();
                 this.win.new_window.el.show();
+                this.win.reload_resources.el.show();
                 break;
         }