src/Builder4/MainWindow.bjs
[app.Builder.js] / src / Builder4 / MainWindow.vala
1 static Xcls_MainWindow  _MainWindow;
2
3 public class Xcls_MainWindow : Object
4 {
5     public Gtk.Window el;
6     private Xcls_MainWindow  _this;
7
8     public static Xcls_MainWindow singleton()
9     {
10         if (_MainWindow == null) {
11             _MainWindow= new Xcls_MainWindow();
12         }
13         return _MainWindow;
14     }
15     public Xcls_headerbar headerbar;
16     public Xcls_topbarmenu topbarmenu;
17     public Xcls_vbox vbox;
18     public Xcls_mainpane mainpane;
19     public Xcls_leftpane leftpane;
20     public Xcls_editpane editpane;
21     public Xcls_tree tree;
22     public Xcls_props props;
23     public Xcls_clutterembed clutterembed;
24     public Xcls_rooview rooview;
25     public Xcls_objectview objectview;
26     public Xcls_codeeditview codeeditview;
27     public Xcls_addpropsview addpropsview;
28     public Xcls_projecteditview projecteditview;
29     public Xcls_buttonlayout buttonlayout;
30     public Xcls_backbutton backbutton;
31     public Xcls_projectbutton projectbutton;
32     public Xcls_editfilebutton editfilebutton;
33     public Xcls_projecteditbutton projecteditbutton;
34     public Xcls_objectshowbutton objectshowbutton;
35     public Xcls_addpropbutton addpropbutton;
36     public Xcls_addlistenerbutton addlistenerbutton;
37     public Xcls_addprojectbutton addprojectbutton;
38     public Xcls_addfilebutton addfilebutton;
39     public Xcls_delprojectbutton delprojectbutton;
40     public Xcls_statusbar statusbar;
41     public Xcls_search_entry search_entry;
42     public Xcls_search_results search_results;
43     public Xcls_statusbar_errors statusbar_errors;
44     public Xcls_statusbar_warnings statusbar_warnings;
45     public Xcls_statusbar_depricated statusbar_depricated;
46     public Xcls_statusbar_run statusbar_run;
47
48         // my vars (def)
49     public Project.Project project;
50     public string title;
51     public int no_windows;
52     public WindowState windowstate;
53
54     // ctor
55     public Xcls_MainWindow()
56     {
57         _this = this;
58         this.el = new Gtk.Window( Gtk.WindowType.TOPLEVEL );
59
60         // my vars (dec)
61         this.project = null;
62         this.title = "Application Builder";
63         this.no_windows = 1;
64         this.windowstate = null;
65
66         // set gobject values
67         this.el.border_width = 0;
68         this.el.default_height = 500;
69         this.el.default_width = 800;
70         var child_0 = new Xcls_headerbar( _this );
71         child_0.ref();
72         this.el.set_titlebar (  child_0.el  );
73         var child_1 = new Xcls_vbox( _this );
74         child_1.ref();
75         this.el.add (  child_1.el  );
76
77         // init method
78
79         //this.el.show_all();
80
81         //listeners
82         this.el.delete_event.connect( (   event) => {
83             return false;
84         });
85         this.el.button_release_event.connect( (event) => {
86             
87             if (event.keyval == Gdk.Key.f && (event.state & Gdk.ModifierType.CONTROL_MASK ) > 0 ) {
88                 print("SAVE: ctrl-f  pressed");
89                         
90                 return false;
91             }
92            // print(event.key.keyval)
93             
94             return false;
95         
96         });
97         this.el.destroy.connect( () =>  {
98          Xcls_MainWindow.singleton().no_windows--;
99          
100          Resources.singleton().disconnect(_this.statusbar.handler_id);
101          
102          
103          if (Xcls_MainWindow.singleton().no_windows < 1) {
104         
105              Gtk.main_quit();
106          }
107         });
108         this.el.show.connect( ( ) => {
109             // hide the file editing..
110            
111             //this.hideViewEditing();
112             _this.statusbar.el.hide();
113              _this.statusbar_errors.el.hide();
114             _this.statusbar_warnings.el.hide();
115             _this.statusbar_depricated.el.hide();
116             
117           
118             Resources.singleton().checkResources();
119         
120         });
121     }
122
123     // user defined functions
124     public        void initChildren () {
125         // this needs putting in a better place..
126         this.windowstate = new WindowState(this);
127          
128     
129         //w.el.show_all();
130         var tl = new Clutter.Timeline(6000);
131         tl.set_repeat_count(-1);
132         tl.start();
133         tl.ref();
134     
135         
136     
137     
138     
139     }
140     public             void show () {
141        
142         this.el.show_all();
143     
144     }
145     public             void setTitle (string str) {
146         this.headerbar.el.set_title(this.title + " - " + str);
147     }
148     public class Xcls_headerbar : Object
149     {
150         public Gtk.HeaderBar el;
151         private Xcls_MainWindow  _this;
152
153
154             // my vars (def)
155
156         // ctor
157         public Xcls_headerbar(Xcls_MainWindow _owner )
158         {
159             _this = _owner;
160             _this.headerbar = this;
161             this.el = new Gtk.HeaderBar();
162
163             // my vars (dec)
164
165             // set gobject values
166             this.el.title = "Application Builder";
167             this.el.show_close_button = true;
168             var child_0 = new Xcls_Box3( _this );
169             child_0.ref();
170             this.el.pack_start (  child_0.el  );
171         }
172
173         // user defined functions
174     }
175     public class Xcls_Box3 : Object
176     {
177         public Gtk.Box el;
178         private Xcls_MainWindow  _this;
179
180
181             // my vars (def)
182
183         // ctor
184         public Xcls_Box3(Xcls_MainWindow _owner )
185         {
186             _this = _owner;
187             this.el = new Gtk.Box( Gtk.Orientation.HORIZONTAL, 0 );
188
189             // my vars (dec)
190
191             // set gobject values
192             var child_0 = new Xcls_MenuButton4( _this );
193             child_0.ref();
194             this.el.add (  child_0.el  );
195         }
196
197         // user defined functions
198     }
199     public class Xcls_MenuButton4 : Object
200     {
201         public Gtk.MenuButton el;
202         private Xcls_MainWindow  _this;
203
204
205             // my vars (def)
206
207         // ctor
208         public Xcls_MenuButton4(Xcls_MainWindow _owner )
209         {
210             _this = _owner;
211             this.el = new Gtk.MenuButton();
212
213             // my vars (dec)
214
215             // set gobject values
216             this.el.use_popover = false;
217             var child_0 = new Xcls_topbarmenu( _this );
218             child_0.ref();
219             this.el.set_popup (  child_0.el  );
220             var child_1 = new Xcls_Image10( _this );
221             child_1.ref();
222             this.el.set_image (  child_1.el  );
223         }
224
225         // user defined functions
226     }
227     public class Xcls_topbarmenu : Object
228     {
229         public Gtk.Menu el;
230         private Xcls_MainWindow  _this;
231
232
233             // my vars (def)
234
235         // ctor
236         public Xcls_topbarmenu(Xcls_MainWindow _owner )
237         {
238             _this = _owner;
239             _this.topbarmenu = this;
240             this.el = new Gtk.Menu();
241
242             // my vars (dec)
243
244             // set gobject values
245             var child_0 = new Xcls_MenuItem6( _this );
246             child_0.ref();
247             this.el.append (  child_0.el  );
248             var child_1 = new Xcls_SeparatorMenuItem7( _this );
249             child_1.ref();
250             this.el.append (  child_1.el  );
251             var child_2 = new Xcls_MenuItem8( _this );
252             child_2.ref();
253             this.el.append (  child_2.el  );
254             var child_3 = new Xcls_MenuItem9( _this );
255             child_3.ref();
256             this.el.append (  child_3.el  );
257
258             // init method
259
260             {
261                 this.el.show_all();
262             }
263         }
264
265         // user defined functions
266     }
267     public class Xcls_MenuItem6 : Object
268     {
269         public Gtk.MenuItem el;
270         private Xcls_MainWindow  _this;
271
272
273             // my vars (def)
274
275         // ctor
276         public Xcls_MenuItem6(Xcls_MainWindow _owner )
277         {
278             _this = _owner;
279             this.el = new Gtk.MenuItem();
280
281             // my vars (dec)
282
283             // set gobject values
284             this.el.label = "Open a new Window";
285
286             //listeners
287             this.el.activate.connect( ( ) => {
288                     Xcls_MainWindow.singleton().no_windows++;
289                     var w = new Xcls_MainWindow();
290                     w.ref();
291             
292                     w.el.show_all();
293                     w.initChildren();
294                     w.windowstate.switchState(WindowState.State.FILES);
295             });
296         }
297
298         // user defined functions
299     }
300
301     public class Xcls_SeparatorMenuItem7 : Object
302     {
303         public Gtk.SeparatorMenuItem el;
304         private Xcls_MainWindow  _this;
305
306
307             // my vars (def)
308
309         // ctor
310         public Xcls_SeparatorMenuItem7(Xcls_MainWindow _owner )
311         {
312             _this = _owner;
313             this.el = new Gtk.SeparatorMenuItem();
314
315             // my vars (dec)
316
317             // set gobject values
318         }
319
320         // user defined functions
321     }
322
323     public class Xcls_MenuItem8 : Object
324     {
325         public Gtk.MenuItem el;
326         private Xcls_MainWindow  _this;
327
328
329             // my vars (def)
330
331         // ctor
332         public Xcls_MenuItem8(Xcls_MainWindow _owner )
333         {
334             _this = _owner;
335             this.el = new Gtk.MenuItem();
336
337             // my vars (dec)
338
339             // set gobject values
340             this.el.label = "Download updated Resources";
341
342             //listeners
343             this.el.activate.connect( ( ) => {
344                      Resources.singleton().fetchStart();
345             });
346         }
347
348         // user defined functions
349     }
350
351     public class Xcls_MenuItem9 : Object
352     {
353         public Gtk.MenuItem el;
354         private Xcls_MainWindow  _this;
355
356
357             // my vars (def)
358
359         // ctor
360         public Xcls_MenuItem9(Xcls_MainWindow _owner )
361         {
362             _this = _owner;
363             this.el = new Gtk.MenuItem();
364
365             // my vars (dec)
366
367             // set gobject values
368             this.el.label = "About the Builder";
369
370             //listeners
371             this.el.activate.connect( () => {
372                 About.singleton().el.show();
373                 });
374         }
375
376         // user defined functions
377     }
378
379
380     public class Xcls_Image10 : Object
381     {
382         public Gtk.Image el;
383         private Xcls_MainWindow  _this;
384
385
386             // my vars (def)
387
388         // ctor
389         public Xcls_Image10(Xcls_MainWindow _owner )
390         {
391             _this = _owner;
392             this.el = new Gtk.Image();
393
394             // my vars (dec)
395
396             // set gobject values
397             this.el.icon_name = "help-about";
398         }
399
400         // user defined functions
401     }
402
403
404
405
406     public class Xcls_vbox : Object
407     {
408         public Gtk.Box el;
409         private Xcls_MainWindow  _this;
410
411
412             // my vars (def)
413
414         // ctor
415         public Xcls_vbox(Xcls_MainWindow _owner )
416         {
417             _this = _owner;
418             _this.vbox = this;
419             this.el = new Gtk.Box( Gtk.Orientation.VERTICAL, 0 );
420
421             // my vars (dec)
422
423             // set gobject values
424             this.el.homogeneous = false;
425             var child_0 = new Xcls_mainpane( _this );
426             child_0.ref();
427             this.el.pack_start (  child_0.el , true,true,0 );
428             var child_1 = new Xcls_Box66( _this );
429             child_1.ref();
430             this.el.pack_end (  child_1.el , false,true,0 );
431         }
432
433         // user defined functions
434     }
435     public class Xcls_mainpane : Object
436     {
437         public Gtk.Paned el;
438         private Xcls_MainWindow  _this;
439
440
441             // my vars (def)
442         public int lastWidth;
443
444         // ctor
445         public Xcls_mainpane(Xcls_MainWindow _owner )
446         {
447             _this = _owner;
448             _this.mainpane = this;
449             this.el = new Gtk.Paned( Gtk.Orientation.HORIZONTAL );
450
451             // my vars (dec)
452             this.lastWidth = 0;
453
454             // set gobject values
455             this.el.position = 400;
456             var child_0 = new Xcls_leftpane( _this );
457             child_0.ref();
458             this.el.add1 (  child_0.el  );
459             var child_1 = new Xcls_Box17( _this );
460             child_1.ref();
461             this.el.add2 (  child_1.el  );
462         }
463
464         // user defined functions
465     }
466     public class Xcls_leftpane : Object
467     {
468         public Gtk.Box el;
469         private Xcls_MainWindow  _this;
470
471
472             // my vars (def)
473
474         // ctor
475         public Xcls_leftpane(Xcls_MainWindow _owner )
476         {
477             _this = _owner;
478             _this.leftpane = this;
479             this.el = new Gtk.Box( Gtk.Orientation.VERTICAL, 0 );
480
481             // my vars (dec)
482
483             // set gobject values
484             var child_0 = new Xcls_editpane( _this );
485             child_0.ref();
486             this.el.pack_start (  child_0.el , true,true,0 );
487         }
488
489         // user defined functions
490     }
491     public class Xcls_editpane : Object
492     {
493         public Gtk.Paned el;
494         private Xcls_MainWindow  _this;
495
496
497             // my vars (def)
498
499         // ctor
500         public Xcls_editpane(Xcls_MainWindow _owner )
501         {
502             _this = _owner;
503             _this.editpane = this;
504             this.el = new Gtk.Paned( Gtk.Orientation.VERTICAL );
505
506             // my vars (dec)
507
508             // set gobject values
509             var child_0 = new Xcls_tree( _this );
510             child_0.ref();
511             this.el.add1 (  child_0.el  );
512             var child_1 = new Xcls_props( _this );
513             child_1.ref();
514             this.el.add2 (  child_1.el  );
515         }
516
517         // user defined functions
518     }
519     public class Xcls_tree : Object
520     {
521         public Gtk.Box el;
522         private Xcls_MainWindow  _this;
523
524
525             // my vars (def)
526
527         // ctor
528         public Xcls_tree(Xcls_MainWindow _owner )
529         {
530             _this = _owner;
531             _this.tree = this;
532             this.el = new Gtk.Box( Gtk.Orientation.VERTICAL, 0 );
533
534             // my vars (dec)
535
536             // set gobject values
537         }
538
539         // user defined functions
540     }
541
542     public class Xcls_props : Object
543     {
544         public Gtk.Box el;
545         private Xcls_MainWindow  _this;
546
547
548             // my vars (def)
549
550         // ctor
551         public Xcls_props(Xcls_MainWindow _owner )
552         {
553             _this = _owner;
554             _this.props = this;
555             this.el = new Gtk.Box( Gtk.Orientation.VERTICAL, 0 );
556
557             // my vars (dec)
558
559             // set gobject values
560         }
561
562         // user defined functions
563     }
564
565
566
567     public class Xcls_Box17 : Object
568     {
569         public Gtk.Box el;
570         private Xcls_MainWindow  _this;
571
572
573             // my vars (def)
574
575         // ctor
576         public Xcls_Box17(Xcls_MainWindow _owner )
577         {
578             _this = _owner;
579             this.el = new Gtk.Box( Gtk.Orientation.VERTICAL, 0 );
580
581             // my vars (dec)
582
583             // set gobject values
584             var child_0 = new Xcls_clutterembed( _this );
585             child_0.ref();
586             this.el.pack_start (  child_0.el , true,true,0 );
587         }
588
589         // user defined functions
590     }
591     public class Xcls_clutterembed : Object
592     {
593         public GtkClutter.Embed el;
594         private Xcls_MainWindow  _this;
595
596
597             // my vars (def)
598
599         // ctor
600         public Xcls_clutterembed(Xcls_MainWindow _owner )
601         {
602             _this = _owner;
603             _this.clutterembed = this;
604             this.el = new GtkClutter.Embed();
605
606             // my vars (dec)
607
608             // set gobject values
609             var child_0 = new Xcls_rooview( _this );
610             child_0.ref();
611             this.el.get_stage().add_child (  child_0.el  );
612             var child_1 = new Xcls_objectview( _this );
613             child_1.ref();
614             this.el.get_stage().add_child (  child_1.el  );
615             var child_2 = new Xcls_codeeditview( _this );
616             child_2.ref();
617             this.el.get_stage().add_child (  child_2.el  );
618             var child_3 = new Xcls_addpropsview( _this );
619             child_3.ref();
620             this.el.get_stage().add_child (  child_3.el  );
621             var child_4 = new Xcls_projecteditview( _this );
622             child_4.ref();
623             this.el.get_stage().add_child (  child_4.el  );
624             var child_5 = new Xcls_buttonlayout( _this );
625             child_5.ref();
626             this.el.get_stage().add_child (  child_5.el  );
627
628             // init method
629
630             var stage = this.el.get_stage();
631                 stage.set_background_color(  Clutter.Color.from_string("#000"));
632
633             //listeners
634             this.el.size_allocate.connect( (  alloc) => {
635                 if (_this.windowstate == null) {
636                     return;
637                 }
638                 _this.windowstate.resizeCanvas(); 
639                     
640             });
641         }
642
643         // user defined functions
644     }
645     public class Xcls_rooview : Object
646     {
647         public GtkClutter.Actor el;
648         private Xcls_MainWindow  _this;
649
650
651             // my vars (def)
652
653         // ctor
654         public Xcls_rooview(Xcls_MainWindow _owner )
655         {
656             _this = _owner;
657             _this.rooview = this;
658             this.el = new GtkClutter.Actor();
659
660             // my vars (dec)
661
662             // set gobject values
663
664             // init method
665
666             {
667                
668                
669                 this.el.add_constraint(
670                     new Clutter.AlignConstraint(
671                         _this.clutterembed.el.get_stage(), 
672                         Clutter.AlignAxis.X_AXIS,
673                         1.0f
674                     )
675                 );
676                     
677                 //this.el.set_position(100,100);
678                 this.el.set_pivot_point(1.0f,1.0f);
679                 
680                 this.el.set_size(_this.clutterembed.el.get_stage().width-50,
681                         _this.clutterembed.el.get_stage().height);
682                         
683             }
684         }
685
686         // user defined functions
687     }
688
689     public class Xcls_objectview : Object
690     {
691         public GtkClutter.Actor el;
692         private Xcls_MainWindow  _this;
693
694
695             // my vars (def)
696
697         // ctor
698         public Xcls_objectview(Xcls_MainWindow _owner )
699         {
700             _this = _owner;
701             _this.objectview = this;
702             this.el = new GtkClutter.Actor();
703
704             // my vars (dec)
705
706             // set gobject values
707
708             // init method
709
710             {
711                
712                /*
713                 this.el.add_constraint(
714                     new Clutter.AlignConstraint(
715                         _this.clutterembed.el.get_stage(), 
716                         Clutter.AlignAxis.X_AXIS,
717                         0.0f
718                     )
719                 );
720                 */
721                 this.el.fixed_x = 50.0f;
722                 this.el.fixed_y = 0.0f;
723                 //this.el.set_position(100,100);
724                 this.el.set_pivot_point(0.0f,0.0f);
725                 this.el.set_scale(0.0f,1.0f);
726                 this.el.set_size((_this.clutterembed.el.get_stage().width-50)/2,
727                         _this.clutterembed.el.get_stage().height);
728                         
729             }
730         }
731
732         // user defined functions
733     }
734
735     public class Xcls_codeeditview : Object
736     {
737         public GtkClutter.Actor el;
738         private Xcls_MainWindow  _this;
739
740
741             // my vars (def)
742
743         // ctor
744         public Xcls_codeeditview(Xcls_MainWindow _owner )
745         {
746             _this = _owner;
747             _this.codeeditview = this;
748             this.el = new GtkClutter.Actor();
749
750             // my vars (dec)
751
752             // set gobject values
753
754             // init method
755
756             {
757                
758                /*
759                 this.el.add_constraint(
760                     new Clutter.AlignConstraint(
761                         _this.clutterembed.el.get_stage(), 
762                         Clutter.AlignAxis.X_AXIS,
763                         0.0f
764                     )
765                 );
766                 */
767                 this.el.fixed_x = 50.0f;
768                 this.el.fixed_y = 0.0f;
769                 //this.el.set_position(100,100);
770                 this.el.set_pivot_point(0.0f,0.0f);
771                 this.el.set_scale(0.0f,1.0f);
772                 this.el.set_size((_this.clutterembed.el.get_stage().width-50)/2,
773                         _this.clutterembed.el.get_stage().height);
774                         
775             }
776         }
777
778         // user defined functions
779     }
780
781     public class Xcls_addpropsview : Object
782     {
783         public GtkClutter.Actor el;
784         private Xcls_MainWindow  _this;
785
786
787             // my vars (def)
788
789         // ctor
790         public Xcls_addpropsview(Xcls_MainWindow _owner )
791         {
792             _this = _owner;
793             _this.addpropsview = this;
794             this.el = new GtkClutter.Actor();
795
796             // my vars (dec)
797
798             // set gobject values
799
800             // init method
801
802             {
803                
804                /*
805                 this.el.add_constraint(
806                     new Clutter.AlignConstraint(
807                         _this.clutterembed.el.get_stage(), 
808                         Clutter.AlignAxis.X_AXIS,
809                         0.0f
810                     )
811                 );
812                 */
813                 this.el.fixed_x = 50.0f;
814                 this.el.fixed_y = 0.0f;
815                 //this.el.set_position(100,100);
816                 this.el.set_pivot_point(0.0f,0.0f);
817                 this.el.set_scale(0.0f,1.0f);
818                 this.el.set_size((_this.clutterembed.el.get_stage().width-50)/2,
819                         _this.clutterembed.el.get_stage().height);
820                         
821             }
822         }
823
824         // user defined functions
825     }
826
827     public class Xcls_projecteditview : Object
828     {
829         public GtkClutter.Actor el;
830         private Xcls_MainWindow  _this;
831
832
833             // my vars (def)
834
835         // ctor
836         public Xcls_projecteditview(Xcls_MainWindow _owner )
837         {
838             _this = _owner;
839             _this.projecteditview = this;
840             this.el = new GtkClutter.Actor();
841
842             // my vars (dec)
843
844             // set gobject values
845
846             // init method
847
848             {
849                
850                
851                 this.el.add_constraint(
852                     new Clutter.AlignConstraint(
853                         _this.clutterembed.el.get_stage(), 
854                         Clutter.AlignAxis.X_AXIS,
855                         1.0f
856                     )
857                 );
858                     
859                 //this.el.set_position(100,100);
860                 this.el.set_pivot_point(0.0f,0.0f);
861                 this.el.set_scale(1.0f,0.0f);
862                 this.el.set_size(_this.clutterembed.el.get_stage().width-50,
863                         _this.clutterembed.el.get_stage().height /2);
864                         
865             }
866         }
867
868         // user defined functions
869     }
870
871     public class Xcls_buttonlayout : Object
872     {
873         public Clutter.Actor el;
874         private Xcls_MainWindow  _this;
875
876
877             // my vars (def)
878
879         // ctor
880         public Xcls_buttonlayout(Xcls_MainWindow _owner )
881         {
882             _this = _owner;
883             _this.buttonlayout = this;
884             this.el = new Clutter.Actor();
885
886             // my vars (dec)
887
888             // set gobject values
889             var child_0 = new Xcls_BoxLayout25( _this );
890             child_0.ref();
891             this.el.layout_manager = child_0.el;
892             var child_1 = new Xcls_backbutton( _this );
893             child_1.ref();
894             this.el.add_child (  child_1.el  );
895             var child_2 = new Xcls_projectbutton( _this );
896             child_2.ref();
897             this.el.add_child (  child_2.el  );
898             var child_3 = new Xcls_editfilebutton( _this );
899             child_3.ref();
900             this.el.add_child (  child_3.el  );
901             var child_4 = new Xcls_projecteditbutton( _this );
902             child_4.ref();
903             this.el.add_child (  child_4.el  );
904             var child_5 = new Xcls_objectshowbutton( _this );
905             child_5.ref();
906             this.el.add_child (  child_5.el  );
907             var child_6 = new Xcls_addpropbutton( _this );
908             child_6.ref();
909             this.el.add_child (  child_6.el  );
910             var child_7 = new Xcls_addlistenerbutton( _this );
911             child_7.ref();
912             this.el.add_child (  child_7.el  );
913             var child_8 = new Xcls_addprojectbutton( _this );
914             child_8.ref();
915             this.el.add_child (  child_8.el  );
916             var child_9 = new Xcls_addfilebutton( _this );
917             child_9.ref();
918             this.el.add_child (  child_9.el  );
919             var child_10 = new Xcls_delprojectbutton( _this );
920             child_10.ref();
921             this.el.add_child (  child_10.el  );
922
923             // init method
924
925             {
926                 
927                 this.el.add_constraint(
928                     new Clutter.AlignConstraint(
929                         _this.clutterembed.el.get_stage(), 
930                         Clutter.AlignAxis.X_AXIS,
931                         0.0f
932                     )
933                 );
934                  
935                 
936                 //this.el.set_position(100,100);
937                 this.el.set_pivot_point(0.5f,0.5f);
938                  this.el.set_size(50,
939                        _this.clutterembed.el.get_stage().height);
940                  
941             }
942         }
943
944         // user defined functions
945     }
946     public class Xcls_BoxLayout25 : Object
947     {
948         public Clutter.BoxLayout el;
949         private Xcls_MainWindow  _this;
950
951
952             // my vars (def)
953
954         // ctor
955         public Xcls_BoxLayout25(Xcls_MainWindow _owner )
956         {
957             _this = _owner;
958             this.el = new Clutter.BoxLayout();
959
960             // my vars (dec)
961
962             // set gobject values
963             this.el.orientation = Clutter.Orientation.VERTICAL;
964         }
965
966         // user defined functions
967     }
968
969     public class Xcls_backbutton : Object
970     {
971         public Clutter.Actor el;
972         private Xcls_MainWindow  _this;
973
974
975             // my vars (def)
976
977         // ctor
978         public Xcls_backbutton(Xcls_MainWindow _owner )
979         {
980             _this = _owner;
981             _this.backbutton = this;
982             this.el = new Clutter.Actor();
983
984             // my vars (dec)
985
986             // set gobject values
987             var child_0 = new Xcls_Actor27( _this );
988             child_0.ref();
989             this.el.add_child (  child_0.el  );
990
991             // init method
992
993             this.el.set_size(50,50);
994         }
995
996         // user defined functions
997     }
998     public class Xcls_Actor27 : Object
999     {
1000         public GtkClutter.Actor el;
1001         private Xcls_MainWindow  _this;
1002
1003
1004             // my vars (def)
1005
1006         // ctor
1007         public Xcls_Actor27(Xcls_MainWindow _owner )
1008         {
1009             _this = _owner;
1010             this.el = new GtkClutter.Actor();
1011
1012             // my vars (dec)
1013
1014             // set gobject values
1015             var child_0 = new Xcls_Button28( _this );
1016             child_0.ref();
1017
1018             // init method
1019
1020             ((Gtk.Container)(this.el.get_widget())).add ( child_0.el);
1021         }
1022
1023         // user defined functions
1024     }
1025     public class Xcls_Button28 : Object
1026     {
1027         public Gtk.Button el;
1028         private Xcls_MainWindow  _this;
1029
1030
1031             // my vars (def)
1032
1033         // ctor
1034         public Xcls_Button28(Xcls_MainWindow _owner )
1035         {
1036             _this = _owner;
1037             this.el = new Gtk.Button();
1038
1039             // my vars (dec)
1040
1041             // set gobject values
1042             this.el.width_request = 50;
1043             this.el.height_request = 50;
1044             this.el.tooltip_text = "Back";
1045             var child_0 = new Xcls_Image29( _this );
1046             child_0.ref();
1047             this.el.set_image (  child_0.el  );
1048
1049             //listeners
1050             this.el.clicked.connect( ( ) => {
1051               
1052                 _this.windowstate.switchState(WindowState.State.PREVIEW);
1053                 
1054             
1055             });
1056         }
1057
1058         // user defined functions
1059     }
1060     public class Xcls_Image29 : Object
1061     {
1062         public Gtk.Image el;
1063         private Xcls_MainWindow  _this;
1064
1065
1066             // my vars (def)
1067
1068         // ctor
1069         public Xcls_Image29(Xcls_MainWindow _owner )
1070         {
1071             _this = _owner;
1072             this.el = new Gtk.Image();
1073
1074             // my vars (dec)
1075
1076             // set gobject values
1077             this.el.icon_name = "go-previous";
1078         }
1079
1080         // user defined functions
1081     }
1082
1083
1084
1085
1086     public class Xcls_projectbutton : Object
1087     {
1088         public Clutter.Actor el;
1089         private Xcls_MainWindow  _this;
1090
1091
1092             // my vars (def)
1093
1094         // ctor
1095         public Xcls_projectbutton(Xcls_MainWindow _owner )
1096         {
1097             _this = _owner;
1098             _this.projectbutton = this;
1099             this.el = new Clutter.Actor();
1100
1101             // my vars (dec)
1102
1103             // set gobject values
1104             var child_0 = new Xcls_Actor31( _this );
1105             child_0.ref();
1106             this.el.add_child (  child_0.el  );
1107
1108             // init method
1109
1110             this.el.set_size(50,50);
1111         }
1112
1113         // user defined functions
1114     }
1115     public class Xcls_Actor31 : Object
1116     {
1117         public GtkClutter.Actor el;
1118         private Xcls_MainWindow  _this;
1119
1120
1121             // my vars (def)
1122
1123         // ctor
1124         public Xcls_Actor31(Xcls_MainWindow _owner )
1125         {
1126             _this = _owner;
1127             this.el = new GtkClutter.Actor();
1128
1129             // my vars (dec)
1130
1131             // set gobject values
1132             var child_0 = new Xcls_Button32( _this );
1133             child_0.ref();
1134
1135             // init method
1136
1137             ((Gtk.Container)(this.el.get_widget())).add ( child_0.el);
1138         }
1139
1140         // user defined functions
1141     }
1142     public class Xcls_Button32 : Object
1143     {
1144         public Gtk.Button el;
1145         private Xcls_MainWindow  _this;
1146
1147
1148             // my vars (def)
1149
1150         // ctor
1151         public Xcls_Button32(Xcls_MainWindow _owner )
1152         {
1153             _this = _owner;
1154             this.el = new Gtk.Button();
1155
1156             // my vars (dec)
1157
1158             // set gobject values
1159             this.el.width_request = 50;
1160             this.el.height_request = 50;
1161             var child_0 = new Xcls_Image33( _this );
1162             child_0.ref();
1163             this.el.set_image (  child_0.el  );
1164
1165             //listeners
1166             this.el.clicked.connect( ( ) => {
1167                _this.windowstate.switchState(WindowState.State.FILES);
1168                   
1169             
1170             });
1171         }
1172
1173         // user defined functions
1174     }
1175     public class Xcls_Image33 : Object
1176     {
1177         public Gtk.Image el;
1178         private Xcls_MainWindow  _this;
1179
1180
1181             // my vars (def)
1182
1183         // ctor
1184         public Xcls_Image33(Xcls_MainWindow _owner )
1185         {
1186             _this = _owner;
1187             this.el = new Gtk.Image();
1188
1189             // my vars (dec)
1190
1191             // set gobject values
1192             this.el.icon_name = "document-open";
1193         }
1194
1195         // user defined functions
1196     }
1197
1198
1199
1200
1201     public class Xcls_editfilebutton : Object
1202     {
1203         public Clutter.Actor el;
1204         private Xcls_MainWindow  _this;
1205
1206
1207             // my vars (def)
1208
1209         // ctor
1210         public Xcls_editfilebutton(Xcls_MainWindow _owner )
1211         {
1212             _this = _owner;
1213             _this.editfilebutton = this;
1214             this.el = new Clutter.Actor();
1215
1216             // my vars (dec)
1217
1218             // set gobject values
1219             var child_0 = new Xcls_Actor35( _this );
1220             child_0.ref();
1221             this.el.add_child (  child_0.el  );
1222
1223             // init method
1224
1225             this.el.set_size(50.0f,50.0f);
1226         }
1227
1228         // user defined functions
1229     }
1230     public class Xcls_Actor35 : Object
1231     {
1232         public GtkClutter.Actor el;
1233         private Xcls_MainWindow  _this;
1234
1235
1236             // my vars (def)
1237
1238         // ctor
1239         public Xcls_Actor35(Xcls_MainWindow _owner )
1240         {
1241             _this = _owner;
1242             this.el = new GtkClutter.Actor();
1243
1244             // my vars (dec)
1245
1246             // set gobject values
1247             var child_0 = new Xcls_Button36( _this );
1248             child_0.ref();
1249
1250             // init method
1251
1252             ((Gtk.Container)(this.el.get_widget())).add ( child_0.el);
1253         }
1254
1255         // user defined functions
1256     }
1257     public class Xcls_Button36 : Object
1258     {
1259         public Gtk.Button el;
1260         private Xcls_MainWindow  _this;
1261
1262
1263             // my vars (def)
1264
1265         // ctor
1266         public Xcls_Button36(Xcls_MainWindow _owner )
1267         {
1268             _this = _owner;
1269             this.el = new Gtk.Button();
1270
1271             // my vars (dec)
1272
1273             // set gobject values
1274             this.el.width_request = 50;
1275             this.el.height_request = 50;
1276             this.el.tooltip_text = "File Details";
1277             var child_0 = new Xcls_Image37( _this );
1278             child_0.ref();
1279             this.el.set_image (  child_0.el  );
1280
1281             //listeners
1282             this.el.clicked.connect( ( ) => {
1283               
1284                 // create a new file in project..
1285                 if (_this.project == null || _this.windowstate.file == null) {
1286                     return  ;
1287                 }
1288                  _this.windowstate.file_details.show(
1289                     _this.windowstate.file, this.el
1290                 );
1291                  
1292                 return  ;    
1293             
1294             
1295             });
1296         }
1297
1298         // user defined functions
1299     }
1300     public class Xcls_Image37 : Object
1301     {
1302         public Gtk.Image el;
1303         private Xcls_MainWindow  _this;
1304
1305
1306             // my vars (def)
1307
1308         // ctor
1309         public Xcls_Image37(Xcls_MainWindow _owner )
1310         {
1311             _this = _owner;
1312             this.el = new Gtk.Image();
1313
1314             // my vars (dec)
1315
1316             // set gobject values
1317             this.el.icon_name = "document-properties";
1318         }
1319
1320         // user defined functions
1321     }
1322
1323
1324
1325
1326     public class Xcls_projecteditbutton : Object
1327     {
1328         public Clutter.Actor el;
1329         private Xcls_MainWindow  _this;
1330
1331
1332             // my vars (def)
1333
1334         // ctor
1335         public Xcls_projecteditbutton(Xcls_MainWindow _owner )
1336         {
1337             _this = _owner;
1338             _this.projecteditbutton = this;
1339             this.el = new Clutter.Actor();
1340
1341             // my vars (dec)
1342
1343             // set gobject values
1344             var child_0 = new Xcls_Actor39( _this );
1345             child_0.ref();
1346             this.el.add_child (  child_0.el  );
1347
1348             // init method
1349
1350             this.el.set_size(50,50);
1351         }
1352
1353         // user defined functions
1354     }
1355     public class Xcls_Actor39 : Object
1356     {
1357         public GtkClutter.Actor el;
1358         private Xcls_MainWindow  _this;
1359
1360
1361             // my vars (def)
1362
1363         // ctor
1364         public Xcls_Actor39(Xcls_MainWindow _owner )
1365         {
1366             _this = _owner;
1367             this.el = new GtkClutter.Actor();
1368
1369             // my vars (dec)
1370
1371             // set gobject values
1372             var child_0 = new Xcls_Button40( _this );
1373             child_0.ref();
1374
1375             // init method
1376
1377             ((Gtk.Container)(this.el.get_widget())).add ( child_0.el);
1378         }
1379
1380         // user defined functions
1381     }
1382     public class Xcls_Button40 : Object
1383     {
1384         public Gtk.Button el;
1385         private Xcls_MainWindow  _this;
1386
1387
1388             // my vars (def)
1389
1390         // ctor
1391         public Xcls_Button40(Xcls_MainWindow _owner )
1392         {
1393             _this = _owner;
1394             this.el = new Gtk.Button();
1395
1396             // my vars (dec)
1397
1398             // set gobject values
1399             this.el.width_request = 50;
1400             this.el.height_request = 50;
1401             this.el.tooltip_text = "Project Details";
1402             var child_0 = new Xcls_Image41( _this );
1403             child_0.ref();
1404             this.el.set_image (  child_0.el  );
1405
1406             //listeners
1407             this.el.clicked.connect( ( ) => {
1408                  _this.windowstate.switchState(WindowState.State.PROJECT);
1409                
1410             
1411             
1412             });
1413         }
1414
1415         // user defined functions
1416     }
1417     public class Xcls_Image41 : Object
1418     {
1419         public Gtk.Image el;
1420         private Xcls_MainWindow  _this;
1421
1422
1423             // my vars (def)
1424
1425         // ctor
1426         public Xcls_Image41(Xcls_MainWindow _owner )
1427         {
1428             _this = _owner;
1429             this.el = new Gtk.Image();
1430
1431             // my vars (dec)
1432
1433             // set gobject values
1434             this.el.icon_name = "emblem-system";
1435         }
1436
1437         // user defined functions
1438     }
1439
1440
1441
1442
1443     public class Xcls_objectshowbutton : Object
1444     {
1445         public Clutter.Actor el;
1446         private Xcls_MainWindow  _this;
1447
1448
1449             // my vars (def)
1450
1451         // ctor
1452         public Xcls_objectshowbutton(Xcls_MainWindow _owner )
1453         {
1454             _this = _owner;
1455             _this.objectshowbutton = this;
1456             this.el = new Clutter.Actor();
1457
1458             // my vars (dec)
1459
1460             // set gobject values
1461             var child_0 = new Xcls_Actor43( _this );
1462             child_0.ref();
1463             this.el.add_child (  child_0.el  );
1464
1465             // init method
1466
1467             this.el.set_size(50,50);
1468
1469             //listeners
1470             this.el.enter_event.connect( (  event)  => {
1471                 this.el.background_color =   Clutter.Color.from_string("#333");
1472                     return false;
1473             });
1474             this.el.leave_event.connect( (  event)  => {
1475                 this.el.background_color =   Clutter.Color.from_string("#000");
1476                 return false;
1477             });
1478         }
1479
1480         // user defined functions
1481     }
1482     public class Xcls_Actor43 : Object
1483     {
1484         public GtkClutter.Actor el;
1485         private Xcls_MainWindow  _this;
1486
1487
1488             // my vars (def)
1489
1490         // ctor
1491         public Xcls_Actor43(Xcls_MainWindow _owner )
1492         {
1493             _this = _owner;
1494             this.el = new GtkClutter.Actor();
1495
1496             // my vars (dec)
1497
1498             // set gobject values
1499             var child_0 = new Xcls_Button44( _this );
1500             child_0.ref();
1501
1502             // init method
1503
1504             ((Gtk.Container)(this.el.get_widget())).add ( child_0.el);
1505         }
1506
1507         // user defined functions
1508     }
1509     public class Xcls_Button44 : Object
1510     {
1511         public Gtk.Button el;
1512         private Xcls_MainWindow  _this;
1513
1514
1515             // my vars (def)
1516
1517         // ctor
1518         public Xcls_Button44(Xcls_MainWindow _owner )
1519         {
1520             _this = _owner;
1521             this.el = new Gtk.Button();
1522
1523             // my vars (dec)
1524
1525             // set gobject values
1526             this.el.width_request = 50;
1527             this.el.height_request = 50;
1528             this.el.tooltip_text = "Add Child Element";
1529             var child_0 = new Xcls_Image45( _this );
1530             child_0.ref();
1531             this.el.set_image (  child_0.el  );
1532
1533             //listeners
1534             this.el.clicked.connect( ( ) => {
1535                 
1536                  _this.windowstate.switchState(WindowState.State.OBJECT);
1537               
1538              
1539             });
1540         }
1541
1542         // user defined functions
1543     }
1544     public class Xcls_Image45 : Object
1545     {
1546         public Gtk.Image el;
1547         private Xcls_MainWindow  _this;
1548
1549
1550             // my vars (def)
1551
1552         // ctor
1553         public Xcls_Image45(Xcls_MainWindow _owner )
1554         {
1555             _this = _owner;
1556             this.el = new Gtk.Image();
1557
1558             // my vars (dec)
1559
1560             // set gobject values
1561             this.el.icon_name = "list-add";
1562         }
1563
1564         // user defined functions
1565     }
1566
1567
1568
1569
1570     public class Xcls_addpropbutton : Object
1571     {
1572         public Clutter.Actor el;
1573         private Xcls_MainWindow  _this;
1574
1575
1576             // my vars (def)
1577
1578         // ctor
1579         public Xcls_addpropbutton(Xcls_MainWindow _owner )
1580         {
1581             _this = _owner;
1582             _this.addpropbutton = this;
1583             this.el = new Clutter.Actor();
1584
1585             // my vars (dec)
1586
1587             // set gobject values
1588             var child_0 = new Xcls_Actor47( _this );
1589             child_0.ref();
1590             this.el.add_child (  child_0.el  );
1591
1592             // init method
1593
1594             this.el.set_size(50,50);
1595         }
1596
1597         // user defined functions
1598     }
1599     public class Xcls_Actor47 : Object
1600     {
1601         public GtkClutter.Actor el;
1602         private Xcls_MainWindow  _this;
1603
1604
1605             // my vars (def)
1606
1607         // ctor
1608         public Xcls_Actor47(Xcls_MainWindow _owner )
1609         {
1610             _this = _owner;
1611             this.el = new GtkClutter.Actor();
1612
1613             // my vars (dec)
1614
1615             // set gobject values
1616             var child_0 = new Xcls_Button48( _this );
1617             child_0.ref();
1618
1619             // init method
1620
1621             ((Gtk.Container)(this.el.get_widget())).add ( child_0.el);
1622         }
1623
1624         // user defined functions
1625     }
1626     public class Xcls_Button48 : Object
1627     {
1628         public Gtk.Button el;
1629         private Xcls_MainWindow  _this;
1630
1631
1632             // my vars (def)
1633
1634         // ctor
1635         public Xcls_Button48(Xcls_MainWindow _owner )
1636         {
1637             _this = _owner;
1638             this.el = new Gtk.Button();
1639
1640             // my vars (dec)
1641
1642             // set gobject values
1643             this.el.width_request = 50;
1644             this.el.height_request = 50;
1645             this.el.tooltip_text = "Add Property";
1646             var child_0 = new Xcls_Image49( _this );
1647             child_0.ref();
1648             this.el.set_image (  child_0.el  );
1649
1650             //listeners
1651             this.el.clicked.connect( ( ) => {
1652                 
1653                  _this.windowstate.switchState(WindowState.State.PROP);
1654              
1655             
1656             });
1657         }
1658
1659         // user defined functions
1660     }
1661     public class Xcls_Image49 : Object
1662     {
1663         public Gtk.Image el;
1664         private Xcls_MainWindow  _this;
1665
1666
1667             // my vars (def)
1668
1669         // ctor
1670         public Xcls_Image49(Xcls_MainWindow _owner )
1671         {
1672             _this = _owner;
1673             this.el = new Gtk.Image();
1674
1675             // my vars (dec)
1676
1677             // set gobject values
1678             this.el.icon_name = "format-justify-left";
1679         }
1680
1681         // user defined functions
1682     }
1683
1684
1685
1686
1687     public class Xcls_addlistenerbutton : Object
1688     {
1689         public Clutter.Actor el;
1690         private Xcls_MainWindow  _this;
1691
1692
1693             // my vars (def)
1694
1695         // ctor
1696         public Xcls_addlistenerbutton(Xcls_MainWindow _owner )
1697         {
1698             _this = _owner;
1699             _this.addlistenerbutton = this;
1700             this.el = new Clutter.Actor();
1701
1702             // my vars (dec)
1703
1704             // set gobject values
1705             var child_0 = new Xcls_Actor51( _this );
1706             child_0.ref();
1707             this.el.add_child (  child_0.el  );
1708
1709             // init method
1710
1711             this.el.set_size(50,50);
1712         }
1713
1714         // user defined functions
1715     }
1716     public class Xcls_Actor51 : Object
1717     {
1718         public GtkClutter.Actor el;
1719         private Xcls_MainWindow  _this;
1720
1721
1722             // my vars (def)
1723
1724         // ctor
1725         public Xcls_Actor51(Xcls_MainWindow _owner )
1726         {
1727             _this = _owner;
1728             this.el = new GtkClutter.Actor();
1729
1730             // my vars (dec)
1731
1732             // set gobject values
1733             var child_0 = new Xcls_Button52( _this );
1734             child_0.ref();
1735
1736             // init method
1737
1738             ((Gtk.Container)(this.el.get_widget())).add ( child_0.el);
1739         }
1740
1741         // user defined functions
1742     }
1743     public class Xcls_Button52 : Object
1744     {
1745         public Gtk.Button el;
1746         private Xcls_MainWindow  _this;
1747
1748
1749             // my vars (def)
1750
1751         // ctor
1752         public Xcls_Button52(Xcls_MainWindow _owner )
1753         {
1754             _this = _owner;
1755             this.el = new Gtk.Button();
1756
1757             // my vars (dec)
1758
1759             // set gobject values
1760             this.el.width_request = 50;
1761             this.el.height_request = 50;
1762             this.el.tooltip_text = "Add Event Code";
1763             var child_0 = new Xcls_Image53( _this );
1764             child_0.ref();
1765             this.el.set_image (  child_0.el  );
1766
1767             //listeners
1768             this.el.clicked.connect( ( ) => {
1769                 
1770                 _this.windowstate.switchState(WindowState.State.LISTENER);
1771               
1772             
1773             
1774             });
1775         }
1776
1777         // user defined functions
1778     }
1779     public class Xcls_Image53 : Object
1780     {
1781         public Gtk.Image el;
1782         private Xcls_MainWindow  _this;
1783
1784
1785             // my vars (def)
1786
1787         // ctor
1788         public Xcls_Image53(Xcls_MainWindow _owner )
1789         {
1790             _this = _owner;
1791             this.el = new Gtk.Image();
1792
1793             // my vars (dec)
1794
1795             // set gobject values
1796             this.el.icon_name = "appointment-new";
1797         }
1798
1799         // user defined functions
1800     }
1801
1802
1803
1804
1805     public class Xcls_addprojectbutton : Object
1806     {
1807         public Clutter.Actor el;
1808         private Xcls_MainWindow  _this;
1809
1810
1811             // my vars (def)
1812
1813         // ctor
1814         public Xcls_addprojectbutton(Xcls_MainWindow _owner )
1815         {
1816             _this = _owner;
1817             _this.addprojectbutton = this;
1818             this.el = new Clutter.Actor();
1819
1820             // my vars (dec)
1821
1822             // set gobject values
1823             var child_0 = new Xcls_Actor55( _this );
1824             child_0.ref();
1825             this.el.add_child (  child_0.el  );
1826
1827             // init method
1828
1829             this.el.set_size(50.0f,50.0f);
1830         }
1831
1832         // user defined functions
1833     }
1834     public class Xcls_Actor55 : Object
1835     {
1836         public GtkClutter.Actor el;
1837         private Xcls_MainWindow  _this;
1838
1839
1840             // my vars (def)
1841
1842         // ctor
1843         public Xcls_Actor55(Xcls_MainWindow _owner )
1844         {
1845             _this = _owner;
1846             this.el = new GtkClutter.Actor();
1847
1848             // my vars (dec)
1849
1850             // set gobject values
1851             var child_0 = new Xcls_Button56( _this );
1852             child_0.ref();
1853
1854             // init method
1855
1856             ((Gtk.Container)(this.el.get_widget())).add ( child_0.el);
1857         }
1858
1859         // user defined functions
1860     }
1861     public class Xcls_Button56 : Object
1862     {
1863         public Gtk.Button el;
1864         private Xcls_MainWindow  _this;
1865
1866
1867             // my vars (def)
1868
1869         // ctor
1870         public Xcls_Button56(Xcls_MainWindow _owner )
1871         {
1872             _this = _owner;
1873             this.el = new Gtk.Button();
1874
1875             // my vars (dec)
1876
1877             // set gobject values
1878             this.el.width_request = 50;
1879             this.el.height_request = 50;
1880             this.el.tooltip_text = "New\nProj.";
1881             var child_0 = new Xcls_Image57( _this );
1882             child_0.ref();
1883             this.el.set_image (  child_0.el  );
1884
1885             //listeners
1886             this.el.clicked.connect( ( ) => {
1887               
1888                 // create a new file in project..
1889                 //Xcls_DialogNewComponent.singleton().show(
1890                var  pe =      EditProject.singleton();
1891                 pe.el.set_transient_for(_this.el);
1892                 pe.el.set_modal(true);   
1893                
1894                 var p  = pe.show();
1895             
1896                 if (p == null) {
1897                     return;
1898                 }
1899                 
1900                 
1901                 _this.windowstate.left_projects.is_loaded = false;    
1902                 _this.windowstate.left_projects.load();
1903                 _this.windowstate.left_projects.selectProject(p);
1904                 return  ;    
1905             
1906             
1907             });
1908         }
1909
1910         // user defined functions
1911     }
1912     public class Xcls_Image57 : Object
1913     {
1914         public Gtk.Image el;
1915         private Xcls_MainWindow  _this;
1916
1917
1918             // my vars (def)
1919
1920         // ctor
1921         public Xcls_Image57(Xcls_MainWindow _owner )
1922         {
1923             _this = _owner;
1924             this.el = new Gtk.Image();
1925
1926             // my vars (dec)
1927
1928             // set gobject values
1929             this.el.icon_name = "folder-new";
1930         }
1931
1932         // user defined functions
1933     }
1934
1935
1936
1937
1938     public class Xcls_addfilebutton : Object
1939     {
1940         public Clutter.Actor el;
1941         private Xcls_MainWindow  _this;
1942
1943
1944             // my vars (def)
1945
1946         // ctor
1947         public Xcls_addfilebutton(Xcls_MainWindow _owner )
1948         {
1949             _this = _owner;
1950             _this.addfilebutton = this;
1951             this.el = new Clutter.Actor();
1952
1953             // my vars (dec)
1954
1955             // set gobject values
1956             var child_0 = new Xcls_Actor59( _this );
1957             child_0.ref();
1958             this.el.add_child (  child_0.el  );
1959
1960             // init method
1961
1962             this.el.set_size(50.0f,50.0f);
1963         }
1964
1965         // user defined functions
1966     }
1967     public class Xcls_Actor59 : Object
1968     {
1969         public GtkClutter.Actor el;
1970         private Xcls_MainWindow  _this;
1971
1972
1973             // my vars (def)
1974
1975         // ctor
1976         public Xcls_Actor59(Xcls_MainWindow _owner )
1977         {
1978             _this = _owner;
1979             this.el = new GtkClutter.Actor();
1980
1981             // my vars (dec)
1982
1983             // set gobject values
1984             var child_0 = new Xcls_Button60( _this );
1985             child_0.ref();
1986
1987             // init method
1988
1989             ((Gtk.Container)(this.el.get_widget())).add ( child_0.el);
1990         }
1991
1992         // user defined functions
1993     }
1994     public class Xcls_Button60 : Object
1995     {
1996         public Gtk.Button el;
1997         private Xcls_MainWindow  _this;
1998
1999
2000             // my vars (def)
2001
2002         // ctor
2003         public Xcls_Button60(Xcls_MainWindow _owner )
2004         {
2005             _this = _owner;
2006             this.el = new Gtk.Button();
2007
2008             // my vars (dec)
2009
2010             // set gobject values
2011             this.el.width_request = 50;
2012             this.el.height_request = 50;
2013             this.el.tooltip_text = "Add File";
2014             var child_0 = new Xcls_Image61( _this );
2015             child_0.ref();
2016             this.el.set_image (  child_0.el  );
2017
2018             //listeners
2019             this.el.clicked.connect( () => {
2020                 // create a new file in project..
2021                 print("add file selected\n");
2022                 // what's the currently selected project...
2023                 var proj = _this.windowstate.left_projects.getSelectedProject();
2024                 
2025                 if (proj == null) {
2026                         print("no project selected?\n");
2027                     return  ;
2028                 }
2029                 
2030                 print("creating file?");
2031                 
2032                 var f = JsRender.JsRender.factory(proj.xtype,  proj, "");
2033                 _this.project = proj;
2034                     print("showing popup?");
2035                  _this.windowstate.file_details.show(
2036                    f, this.el
2037                 );
2038                 
2039                 
2040                 return  ;    
2041             });
2042         }
2043
2044         // user defined functions
2045     }
2046     public class Xcls_Image61 : Object
2047     {
2048         public Gtk.Image el;
2049         private Xcls_MainWindow  _this;
2050
2051
2052             // my vars (def)
2053
2054         // ctor
2055         public Xcls_Image61(Xcls_MainWindow _owner )
2056         {
2057             _this = _owner;
2058             this.el = new Gtk.Image();
2059
2060             // my vars (dec)
2061
2062             // set gobject values
2063             this.el.icon_name = "document-new";
2064         }
2065
2066         // user defined functions
2067     }
2068
2069
2070
2071
2072     public class Xcls_delprojectbutton : Object
2073     {
2074         public Clutter.Actor el;
2075         private Xcls_MainWindow  _this;
2076
2077
2078             // my vars (def)
2079
2080         // ctor
2081         public Xcls_delprojectbutton(Xcls_MainWindow _owner )
2082         {
2083             _this = _owner;
2084             _this.delprojectbutton = this;
2085             this.el = new Clutter.Actor();
2086
2087             // my vars (dec)
2088
2089             // set gobject values
2090             var child_0 = new Xcls_Actor63( _this );
2091             child_0.ref();
2092             this.el.add_child (  child_0.el  );
2093
2094             // init method
2095
2096             this.el.set_size(50,50);
2097         }
2098
2099         // user defined functions
2100     }
2101     public class Xcls_Actor63 : Object
2102     {
2103         public GtkClutter.Actor el;
2104         private Xcls_MainWindow  _this;
2105
2106
2107             // my vars (def)
2108
2109         // ctor
2110         public Xcls_Actor63(Xcls_MainWindow _owner )
2111         {
2112             _this = _owner;
2113             this.el = new GtkClutter.Actor();
2114
2115             // my vars (dec)
2116
2117             // set gobject values
2118             var child_0 = new Xcls_Button64( _this );
2119             child_0.ref();
2120
2121             // init method
2122
2123             ((Gtk.Container)(this.el.get_widget())).add ( child_0.el);
2124         }
2125
2126         // user defined functions
2127     }
2128     public class Xcls_Button64 : Object
2129     {
2130         public Gtk.Button el;
2131         private Xcls_MainWindow  _this;
2132
2133
2134             // my vars (def)
2135
2136         // ctor
2137         public Xcls_Button64(Xcls_MainWindow _owner )
2138         {
2139             _this = _owner;
2140             this.el = new Gtk.Button();
2141
2142             // my vars (dec)
2143
2144             // set gobject values
2145             this.el.width_request = 50;
2146             this.el.height_request = 50;
2147             this.el.tooltip_text = "Delete Project";
2148             var child_0 = new Xcls_Image65( _this );
2149             child_0.ref();
2150             this.el.set_image (  child_0.el  );
2151
2152             //listeners
2153             this.el.clicked.connect( ( ) => {
2154                  
2155                  var cd = DialogConfirm.singleton();
2156                  cd.el.set_transient_for(_this.el);
2157                 cd.el.set_modal(true);
2158             
2159                  var project =   _this.windowstate.left_projects.getSelectedProject();
2160                 if (project == null) {
2161                     print("SKIP - no project\n");
2162                     return;
2163                 }
2164                 
2165                     
2166                  if (Gtk.ResponseType.YES != cd.show("Confirm", 
2167                     "Are you sure you want to delete project %s".printf(project.name))) {
2168                     return;
2169                 }
2170                  
2171             
2172                 // confirm?
2173                 Project.Project.remove(project);
2174                 _this.project = null;
2175                 
2176                 _this.windowstate.left_projects.is_loaded =  false;
2177                 _this.windowstate.left_projects.load();
2178                 _this.windowstate.clutterfiles.clearFiles();
2179             
2180             });
2181         }
2182
2183         // user defined functions
2184     }
2185     public class Xcls_Image65 : Object
2186     {
2187         public Gtk.Image el;
2188         private Xcls_MainWindow  _this;
2189
2190
2191             // my vars (def)
2192
2193         // ctor
2194         public Xcls_Image65(Xcls_MainWindow _owner )
2195         {
2196             _this = _owner;
2197             this.el = new Gtk.Image();
2198
2199             // my vars (dec)
2200
2201             // set gobject values
2202             this.el.icon_name = "user-trash";
2203         }
2204
2205         // user defined functions
2206     }
2207
2208
2209
2210
2211
2212
2213
2214
2215     public class Xcls_Box66 : Object
2216     {
2217         public Gtk.Box el;
2218         private Xcls_MainWindow  _this;
2219
2220
2221             // my vars (def)
2222
2223         // ctor
2224         public Xcls_Box66(Xcls_MainWindow _owner )
2225         {
2226             _this = _owner;
2227             this.el = new Gtk.Box( Gtk.Orientation.HORIZONTAL, 0 );
2228
2229             // my vars (dec)
2230
2231             // set gobject values
2232             this.el.homogeneous = false;
2233             var child_0 = new Xcls_Label67( _this );
2234             child_0.ref();
2235             this.el.pack_start (  child_0.el , true,true,0 );
2236             var child_1 = new Xcls_statusbar( _this );
2237             child_1.ref();
2238             this.el.pack_start (  child_1.el , true,true,0 );
2239             var child_2 = new Xcls_search_entry( _this );
2240             child_2.ref();
2241             this.el.pack_start (  child_2.el , false,true,0 );
2242             var child_3 = new Xcls_MenuBar70( _this );
2243             child_3.ref();
2244             this.el.pack_end (  child_3.el , false,true,0 );
2245         }
2246
2247         // user defined functions
2248     }
2249     public class Xcls_Label67 : Object
2250     {
2251         public Gtk.Label el;
2252         private Xcls_MainWindow  _this;
2253
2254
2255             // my vars (def)
2256
2257         // ctor
2258         public Xcls_Label67(Xcls_MainWindow _owner )
2259         {
2260             _this = _owner;
2261             this.el = new Gtk.Label( "   " );
2262
2263             // my vars (dec)
2264
2265             // set gobject values
2266         }
2267
2268         // user defined functions
2269     }
2270
2271     public class Xcls_statusbar : Object
2272     {
2273         public Gtk.ProgressBar el;
2274         private Xcls_MainWindow  _this;
2275
2276
2277             // my vars (def)
2278         public ulong handler_id;
2279
2280         // ctor
2281         public Xcls_statusbar(Xcls_MainWindow _owner )
2282         {
2283             _this = _owner;
2284             _this.statusbar = this;
2285             this.el = new Gtk.ProgressBar();
2286
2287             // my vars (dec)
2288             this.handler_id = -1;
2289
2290             // set gobject values
2291             this.el.show_text = true;
2292
2293             // init method
2294
2295             {
2296                  this.handler_id = Resources.singleton().updateProgress.connect((pos,total) => {
2297                     if (pos < 1) {
2298                         this.el.hide();
2299                         _this.mainpane.el.set_sensitive(true);
2300                         
2301                         return;
2302                     }
2303                      _this.mainpane.el.set_sensitive(false);
2304                      this.el.show();
2305                      this.el.set_fraction ((1.0f * pos) / (1.0f * total));
2306                      this.el.set_text("Fetching Resource : %s/%s".printf(pos.to_string(), total.to_string()));
2307                    
2308                  });
2309             }
2310         }
2311
2312         // user defined functions
2313     }
2314
2315     public class Xcls_search_entry : Object
2316     {
2317         public Gtk.Entry el;
2318         private Xcls_MainWindow  _this;
2319
2320
2321             // my vars (def)
2322
2323         // ctor
2324         public Xcls_search_entry(Xcls_MainWindow _owner )
2325         {
2326             _this = _owner;
2327             _this.search_entry = this;
2328             this.el = new Gtk.Entry();
2329
2330             // my vars (dec)
2331
2332             // set gobject values
2333
2334             // init method
2335
2336             var description =   Pango.FontDescription.from_string("monospace");
2337                 description.set_size(8000);
2338                  this.el.override_font(description);
2339
2340             //listeners
2341             this.el.changed.connect( () => {
2342                 if (this.el.text == "") {
2343                         return;
2344                 }
2345                 Gee.ArrayList<int> res = new Gee.ArrayList<int>();
2346                 switch(_this.windowstate.state) {
2347                         case WindowState.State.CODEONLY:
2348                         case WindowState.State.CODE:
2349                                 // search the code being edited..
2350                                 res = _this.windowstate.code_editor.search(this.el.text);
2351                                 
2352                                 break;
2353                         case WindowState.State.PREVIEW:
2354                                 if (_this.windowstate.file.xtype == "Gtk") {
2355                                          res = _this.windowstate.window_gladeview.search(this.el.text);
2356                                 }
2357                         
2358                         
2359                                 break;
2360                 }
2361                 if (res.size > 0) {
2362                         _this.search_results.el.label = "%d Matches".printf(res.size);
2363                 } else {
2364                         _this.search_results.el.label = "No Matches";
2365                 }
2366                         
2367                 
2368                 
2369             });
2370         }
2371
2372         // user defined functions
2373     }
2374
2375     public class Xcls_MenuBar70 : Object
2376     {
2377         public Gtk.MenuBar el;
2378         private Xcls_MainWindow  _this;
2379
2380
2381             // my vars (def)
2382
2383         // ctor
2384         public Xcls_MenuBar70(Xcls_MainWindow _owner )
2385         {
2386             _this = _owner;
2387             this.el = new Gtk.MenuBar();
2388
2389             // my vars (dec)
2390
2391             // set gobject values
2392             var child_0 = new Xcls_search_results( _this );
2393             child_0.ref();
2394             this.el.add (  child_0.el  );
2395             var child_1 = new Xcls_MenuItem73( _this );
2396             child_1.ref();
2397             this.el.add (  child_1.el  );
2398             var child_2 = new Xcls_statusbar_errors( _this );
2399             child_2.ref();
2400             this.el.add (  child_2.el  );
2401             var child_3 = new Xcls_statusbar_warnings( _this );
2402             child_3.ref();
2403             this.el.add (  child_3.el  );
2404             var child_4 = new Xcls_statusbar_depricated( _this );
2405             child_4.ref();
2406             this.el.add (  child_4.el  );
2407             var child_5 = new Xcls_statusbar_run( _this );
2408             child_5.ref();
2409             this.el.add (  child_5.el  );
2410         }
2411
2412         // user defined functions
2413     }
2414     public class Xcls_search_results : Object
2415     {
2416         public Gtk.ImageMenuItem el;
2417         private Xcls_MainWindow  _this;
2418
2419
2420             // my vars (def)
2421         public Xcls_ValaCompileErrors popup;
2422
2423         // ctor
2424         public Xcls_search_results(Xcls_MainWindow _owner )
2425         {
2426             _this = _owner;
2427             _this.search_results = this;
2428             this.el = new Gtk.ImageMenuItem();
2429
2430             // my vars (dec)
2431
2432             // set gobject values
2433             this.el.always_show_image = true;
2434             this.el.label = "Matches";
2435             var child_0 = new Xcls_Image72( _this );
2436             child_0.ref();
2437             this.el.set_image (  child_0.el  );
2438
2439             //listeners
2440             this.el.button_press_event.connect( () => {
2441             /*
2442                 if (this.popup == null) {
2443                     this.popup = new Xcls_ValaCompileErrors();
2444                     this.popup.window = _this;
2445                 }
2446                
2447                 
2448                 this.popup.show(this.notices, this.el);
2449                 */
2450                 return true;
2451             });
2452         }
2453
2454         // user defined functions
2455     }
2456     public class Xcls_Image72 : Object
2457     {
2458         public Gtk.Image el;
2459         private Xcls_MainWindow  _this;
2460
2461
2462             // my vars (def)
2463
2464         // ctor
2465         public Xcls_Image72(Xcls_MainWindow _owner )
2466         {
2467             _this = _owner;
2468             this.el = new Gtk.Image();
2469
2470             // my vars (dec)
2471
2472             // set gobject values
2473             this.el.icon_name = "system-search";
2474             this.el.sensitive = false;
2475         }
2476
2477         // user defined functions
2478     }
2479
2480
2481     public class Xcls_MenuItem73 : Object
2482     {
2483         public Gtk.MenuItem el;
2484         private Xcls_MainWindow  _this;
2485
2486
2487             // my vars (def)
2488
2489         // ctor
2490         public Xcls_MenuItem73(Xcls_MainWindow _owner )
2491         {
2492             _this = _owner;
2493             this.el = new Gtk.MenuItem();
2494
2495             // my vars (dec)
2496
2497             // set gobject values
2498             this.el.label = "Compile Status:";
2499         }
2500
2501         // user defined functions
2502     }
2503
2504     public class Xcls_statusbar_errors : Object
2505     {
2506         public Gtk.ImageMenuItem el;
2507         private Xcls_MainWindow  _this;
2508
2509
2510             // my vars (def)
2511         public Xcls_ValaCompileErrors popup;
2512         public Json.Object notices;
2513
2514         // ctor
2515         public Xcls_statusbar_errors(Xcls_MainWindow _owner )
2516         {
2517             _this = _owner;
2518             _this.statusbar_errors = this;
2519             this.el = new Gtk.ImageMenuItem();
2520
2521             // my vars (dec)
2522             this.notices = new Json.Object() ;
2523
2524             // set gobject values
2525             this.el.always_show_image = true;
2526             this.el.label = "Errors";
2527             var child_0 = new Xcls_Image75( _this );
2528             child_0.ref();
2529             this.el.set_image (  child_0.el  );
2530
2531             //listeners
2532             this.el.button_press_event.connect( () => {
2533                 if (this.popup == null) {
2534                     this.popup = new Xcls_ValaCompileErrors();
2535                     this.popup.window = _this;
2536                 }
2537                
2538                 
2539                 this.popup.show(this.notices, this.el);
2540                 return true;
2541             });
2542         }
2543
2544         // user defined functions
2545         public void setNotices (Json.Object nots, int qty) {
2546             this.el.show();
2547             this.el.label = qty.to_string() + " Errors";
2548             this.notices = nots;
2549         
2550         }
2551     }
2552     public class Xcls_Image75 : Object
2553     {
2554         public Gtk.Image el;
2555         private Xcls_MainWindow  _this;
2556
2557
2558             // my vars (def)
2559
2560         // ctor
2561         public Xcls_Image75(Xcls_MainWindow _owner )
2562         {
2563             _this = _owner;
2564             this.el = new Gtk.Image();
2565
2566             // my vars (dec)
2567
2568             // set gobject values
2569             this.el.icon_name = "dialog-error";
2570         }
2571
2572         // user defined functions
2573     }
2574
2575
2576     public class Xcls_statusbar_warnings : Object
2577     {
2578         public Gtk.ImageMenuItem el;
2579         private Xcls_MainWindow  _this;
2580
2581
2582             // my vars (def)
2583         public Xcls_ValaCompileErrors popup;
2584         public Json.Object notices;
2585
2586         // ctor
2587         public Xcls_statusbar_warnings(Xcls_MainWindow _owner )
2588         {
2589             _this = _owner;
2590             _this.statusbar_warnings = this;
2591             this.el = new Gtk.ImageMenuItem();
2592
2593             // my vars (dec)
2594             this.notices = new Json.Object();
2595
2596             // set gobject values
2597             this.el.always_show_image = true;
2598             this.el.label = "Warnings";
2599             var child_0 = new Xcls_Image77( _this );
2600             child_0.ref();
2601             this.el.set_image (  child_0.el  );
2602
2603             //listeners
2604             this.el.button_press_event.connect( () => {
2605                 if (this.popup == null) {
2606                     this.popup = new Xcls_ValaCompileErrors();
2607                     this.popup.window = _this;
2608                 }
2609                 
2610                 this.popup.show(this.notices, this.el);
2611                 return true;
2612             });
2613         }
2614
2615         // user defined functions
2616         public void setNotices (Json.Object nots, int qty) {
2617             this.el.show();
2618             this.el.label = qty.to_string() + " Warnings";
2619             this.notices = nots;
2620         
2621         }
2622     }
2623     public class Xcls_Image77 : Object
2624     {
2625         public Gtk.Image el;
2626         private Xcls_MainWindow  _this;
2627
2628
2629             // my vars (def)
2630
2631         // ctor
2632         public Xcls_Image77(Xcls_MainWindow _owner )
2633         {
2634             _this = _owner;
2635             this.el = new Gtk.Image();
2636
2637             // my vars (dec)
2638
2639             // set gobject values
2640             this.el.icon_name = "dialog-warning";
2641         }
2642
2643         // user defined functions
2644     }
2645
2646
2647     public class Xcls_statusbar_depricated : Object
2648     {
2649         public Gtk.ImageMenuItem el;
2650         private Xcls_MainWindow  _this;
2651
2652
2653             // my vars (def)
2654         public Xcls_ValaCompileErrors popup;
2655         public Json.Object notices;
2656
2657         // ctor
2658         public Xcls_statusbar_depricated(Xcls_MainWindow _owner )
2659         {
2660             _this = _owner;
2661             _this.statusbar_depricated = this;
2662             this.el = new Gtk.ImageMenuItem();
2663
2664             // my vars (dec)
2665             this.notices = new Json.Object();
2666
2667             // set gobject values
2668             this.el.always_show_image = true;
2669             this.el.label = "Depricated";
2670             var child_0 = new Xcls_Image79( _this );
2671             child_0.ref();
2672             this.el.set_image (  child_0.el  );
2673
2674             //listeners
2675             this.el.button_press_event.connect( () => {
2676                 if (this.popup == null) {
2677                     this.popup = new Xcls_ValaCompileErrors();
2678                     this.popup.window = _this;
2679                 }
2680                 
2681                 
2682                 this.popup.show(this.notices, this.el);
2683                 return true;
2684             });
2685         }
2686
2687         // user defined functions
2688         public void setNotices (Json.Object nots, int qty) {
2689             this.el.show();
2690             this.el.label = qty.to_string() + " Depricated";
2691             this.notices = nots;
2692         
2693         }
2694     }
2695     public class Xcls_Image79 : Object
2696     {
2697         public Gtk.Image el;
2698         private Xcls_MainWindow  _this;
2699
2700
2701             // my vars (def)
2702
2703         // ctor
2704         public Xcls_Image79(Xcls_MainWindow _owner )
2705         {
2706             _this = _owner;
2707             this.el = new Gtk.Image();
2708
2709             // my vars (dec)
2710
2711             // set gobject values
2712             this.el.icon_name = "dialog-information";
2713         }
2714
2715         // user defined functions
2716     }
2717
2718
2719     public class Xcls_statusbar_run : Object
2720     {
2721         public Gtk.ImageMenuItem el;
2722         private Xcls_MainWindow  _this;
2723
2724
2725             // my vars (def)
2726         public Xcls_ValaCompileErrors popup;
2727
2728         // ctor
2729         public Xcls_statusbar_run(Xcls_MainWindow _owner )
2730         {
2731             _this = _owner;
2732             _this.statusbar_run = this;
2733             this.el = new Gtk.ImageMenuItem();
2734
2735             // my vars (dec)
2736
2737             // set gobject values
2738             this.el.always_show_image = true;
2739             this.el.label = "Run";
2740             var child_0 = new Xcls_Image81( _this );
2741             child_0.ref();
2742             this.el.set_image (  child_0.el  );
2743
2744             //listeners
2745             this.el.button_press_event.connect( () => {
2746                 if (_this.windowstate.file == null) {
2747                         return true;
2748                 }
2749                 _this.windowstate.valasource.spawnExecute(_this.windowstate.file);
2750                 
2751                 _this.windowstate.compile_results.show(this.el,true);
2752                 
2753                 return true;
2754             });
2755         }
2756
2757         // user defined functions
2758     }
2759     public class Xcls_Image81 : Object
2760     {
2761         public Gtk.Image el;
2762         private Xcls_MainWindow  _this;
2763
2764
2765             // my vars (def)
2766
2767         // ctor
2768         public Xcls_Image81(Xcls_MainWindow _owner )
2769         {
2770             _this = _owner;
2771             this.el = new Gtk.Image();
2772
2773             // my vars (dec)
2774
2775             // set gobject values
2776             this.el.icon_name = "media-playback-start";
2777         }
2778
2779         // user defined functions
2780     }
2781
2782
2783
2784
2785
2786 }