resources/RooUsage.txt
[app.Builder.js] / src / Builder4 / MainWindow.vala
index cef90a6..d62b8db 100644 (file)
@@ -79,6 +79,11 @@ public class Xcls_MainWindow : Object
         // init method
 
         //this.el.show_all();
+            //try {
+                 this.el.set_icon_name("roobuilder");
+               //} catch (Exception e) {
+               //      print("no icon found");
+        //     }
 
         //listeners
         this.el.delete_event.connect( (   event) => {
@@ -1187,17 +1192,11 @@ public class Xcls_MainWindow : Object
 
             //listeners
             this.el.clicked.connect( ( ) => {
-              
-               switch(_this.windowstate.state) {
-                       case   WindowState.State.FILEPROJECT:
-                                _this.windowstate.switchState(WindowState.State.FILES);
-                                break;
-                       case   WindowState.State.PROJECTCODEONLY:
-                                _this.windowstate.switchState(WindowState.State.CODEONLY);
-                                break;
-                        default: 
-                                _this.windowstate.switchState(WindowState.State.PREVIEW);
-                               break;
+               if (_this.windowstate.state == WindowState.State.FILEPROJECT) {
+                
+                    _this.windowstate.switchState(WindowState.State.FILES);
+                 } else { 
+                   _this.windowstate.switchState(WindowState.State.PREVIEW);
                 }
                 
             
@@ -1439,19 +1438,16 @@ public class Xcls_MainWindow : Object
 
             //listeners
             this.el.clicked.connect( ( ) => {
-                
-                 switch(_this.windowstate.state) {
-                  case WindowState.State.FILES:
-                          _this.windowstate.switchState(WindowState.State.FILEPROJECT);
-                          break;
-                  case WindowState.State.CODEONLY:
-                          _this.windowstate.switchState(WindowState.State.PROJECTCODEONLY);
-                          break;
-                  default:
+                 
+                 if (_this.windowstate.state == WindowState.State.FILES) {
+                 
+                    _this.windowstate.switchState(WindowState.State.FILEPROJECT);
+                 } else {
                     _this.windowstate.switchState(WindowState.State.PROJECT);
-                    break;
                 }     
-                
+               
+            
+            
             });
         }