Clones.bjs
[gitlive] / Clones.vala
1 static Clones  _Clones;
2
3 public class Clones : Object
4 {
5     public Gtk.Dialog el;
6     private Clones  _this;
7
8     public static Clones singleton()
9     {
10         if (_Clones == null) {
11             _Clones= new Clones();
12         }
13         return _Clones;
14     }
15     public Xcls_ok_button ok_button;
16     public Xcls_reposView reposView;
17     public Xcls_reposStore reposStore;
18     public Xcls_tv_autocommit tv_autocommit;
19     public Xcls_cr_autocommit cr_autocommit;
20     public Xcls_tv_autopush tv_autopush;
21     public Xcls_cr_autopush cr_autopush;
22     public Xcls_tv_autobranch tv_autobranch;
23     public Xcls_cr_autobranch cr_autobranch;
24     public Xcls_tv_repo tv_repo;
25     public Xcls_cr_repo cr_repo;
26     public Xcls_tv_active_ticket tv_active_ticket;
27     public Xcls_cr_active_ticket cr_active_ticket;
28     public Xcls_tv_current_branch tv_current_branch;
29     public Xcls_cr_current_branch cr_current_branch;
30     public Xcls_tv_last_updated tv_last_updated;
31     public Xcls_cr_last_updated cr_last_updated;
32     public Xcls_tv_all_branches tv_all_branches;
33     public Xcls_cr_all_branches cr_all_branches;
34     public Xcls_ok_button ok_button;
35
36         // my vars (def)
37
38     // ctor
39     public Clones()
40     {
41         _this = this;
42         this.el = new Gtk.Dialog();
43
44         // my vars (dec)
45
46         // set gobject values
47         this.el.title = "Manage Clones";
48         this.el.border_width = 3;
49         this.el.default_height = 500;
50         this.el.default_width = 1024;
51         this.el.deletable = true;
52         this.el.modal = true;
53         var child_0 = new Xcls_Box2( _this );
54         child_0.ref();
55         this.el.get_content_area().add (  child_0.el  );
56         var child_1 = new Xcls_ok_button( _this );
57         child_1.ref();
58         this.el.add_action_widget (  child_1.el , 1  );
59
60         //listeners
61         this.el.delete_event.connect( (self, event) => {
62             this.el.hide();
63             return true; 
64             //test  
65         });
66         this.el.response.connect( (self, response_id) =>  { 
67          
68                 this.el.hide();
69           
70         });
71     }
72
73     // user defined functions
74     public void show ()    {
75     
76         
77         this.el.set_deletable(false);
78         this.el.set_gravity(Gdk.Gravity.NORTH);
79         this.el.move((Gdk.Screen.width() / 2 ) -400 ,0);
80         
81         this.el.set_default_size(
82                         int.min(1024,Gdk.Screen.width()),
83                         int.max(500,Gdk.Screen.width() - 300)
84         );
85         
86         this.el.show_all();
87         _this.reposStore.load();
88         this.el.set_keep_above(true);
89         this.el.run();
90         // load clones..
91     //     this.get('/reposStore').load();
92         
93         //this.get('/ok_button').el.set_sensitive(false);
94         
95         // block until we return.
96     //    var run_ret = this.el.run();
97     //    if (run_ret < 1 ) {
98     //        return  "DONE";
99     //    }
100     //    print("RUN RETURN : " + run_ret);
101     //    return "DONE";
102         //print(JSON.stringify(this.get('bug').getValue()));
103        // return this.get('bug').getValue();
104         //this.success = c.success;
105     }
106     public class Xcls_Box2 : Object
107     {
108         public Gtk.Box el;
109         private Clones  _this;
110
111
112             // my vars (def)
113
114         // ctor
115         public Xcls_Box2(Clones _owner )
116         {
117             _this = _owner;
118             this.el = new Gtk.Box( Gtk.Orientation.VERTICAL, 0 );
119
120             // my vars (dec)
121
122             // set gobject values
123             var child_0 = new Xcls_Box3( _this );
124             child_0.ref();
125             this.el.pack_start (  child_0.el , false,false,0 );
126             var child_1 = new Xcls_ScrolledWindow10( _this );
127             child_1.ref();
128             this.el.pack_end (  child_1.el , true,true,0 );
129         }
130
131         // user defined functions
132     }
133     public class Xcls_Box3 : Object
134     {
135         public Gtk.Box el;
136         private Clones  _this;
137
138
139             // my vars (def)
140
141         // ctor
142         public Xcls_Box3(Clones _owner )
143         {
144             _this = _owner;
145             this.el = new Gtk.Box( Gtk.Orientation.HORIZONTAL, 0 );
146
147             // my vars (dec)
148
149             // set gobject values
150             var child_0 = new Xcls_Button4( _this );
151             child_0.ref();
152             this.el.add (  child_0.el  );
153             var child_1 = new Xcls_Button5( _this );
154             child_1.ref();
155             this.el.add (  child_1.el  );
156             var child_2 = new Xcls_Button6( _this );
157             child_2.ref();
158             this.el.add (  child_2.el  );
159             var child_3 = new Xcls_Button7( _this );
160             child_3.ref();
161             this.el.add (  child_3.el  );
162             var child_4 = new Xcls_Button8( _this );
163             child_4.ref();
164             this.el.add (  child_4.el  );
165             var child_5 = new Xcls_ok_button( _this );
166             child_5.ref();
167             this.el.add (  child_5.el  );
168         }
169
170         // user defined functions
171     }
172     public class Xcls_Button4 : Object
173     {
174         public Gtk.Button el;
175         private Clones  _this;
176
177
178             // my vars (def)
179
180         // ctor
181         public Xcls_Button4(Clones _owner )
182         {
183             _this = _owner;
184             this.el = new Gtk.Button();
185
186             // my vars (dec)
187
188             // set gobject values
189             this.el.label = "Remotes / Clones";
190
191             //listeners
192             this.el.clicked.connect( () => {
193             
194             /*    var rv = this.get('/reposView');
195                 var rs = this.get('/reposStore');
196                 if (rv.el.get_selection().count_selected_rows() != 1) {
197                     //nothing?
198                     // error condition.
199                     return;
200                 }
201                 var Remotes =     imports.Remotes.Remotes;
202                 
203              
204                 var ret = {};       
205                 var s = rv.el.get_selection();
206                 var path = '';
207                 s.selected_foreach(function(model,p,iter) {
208                                                                 
209                    path = model.get_value(iter, 6).value.get_string();
210                  
211                 }); 
212             
213                 var repo = false;
214                 rs.repos.forEach(function(r) {
215                     if (r.repopath == path) {
216                         repo = r;
217                     
218                     }
219                 
220                 });
221                 Remotes.repo = repo;
222                 Remotes.el.set_transient_for(Clones.el);
223                 Clones.el.set_title("Manage Clones - " + repo.repopath);
224                 Remotes.show();
225                 Clones.el.set_title("Manage Clones");
226             
227               */   
228                 
229                  
230             
231                    
232                 
233                 
234             });
235         }
236
237         // user defined functions
238     }
239
240     public class Xcls_Button5 : Object
241     {
242         public Gtk.Button el;
243         private Clones  _this;
244
245
246             // my vars (def)
247
248         // ctor
249         public Xcls_Button5(Clones _owner )
250         {
251             _this = _owner;
252             this.el = new Gtk.Button();
253
254             // my vars (dec)
255
256             // set gobject values
257             this.el.label = "Branches";
258
259             //listeners
260             this.el.clicked.connect( () => {
261             // 
262             
263                 //NewBranch.singleton().show();
264             
265             /*
266                 var rv = this.get('/reposView');
267                 var rs = this.get('/reposStore');
268                 if (rv.el.get_selection().count_selected_rows() != 1) {
269                     //nothing?
270                     // error condition.
271                     return;
272                 }
273                 var Branches =     imports.Branches.Branches;
274                 
275              
276                 var ret = {};       
277                 var s = rv.el.get_selection();
278                 var path = '';
279                 s.selected_foreach(function(model,p,iter) {
280                                                                 
281                    path = model.get_value(iter, 6).value.get_string();
282                  
283                 }); 
284             
285                 var repo = false;
286                 rs.repos.forEach(function(r) {
287                     if (r.repopath == path) {
288                         repo = r;
289                     
290                     }
291                 
292                 });
293                 Branches.repo = repo;
294                 Branches.el.set_transient_for(Clones.el);
295                 Clones.el.set_title("Manage Clones - " + repo.repopath);
296                 Branches.show();
297                 Clones.el.set_title("Manage Clones");
298             
299                  
300                 
301                 
302                 
303             
304                    
305              */   
306                 
307             });
308         }
309
310         // user defined functions
311     }
312
313     public class Xcls_Button6 : Object
314     {
315         public Gtk.Button el;
316         private Clones  _this;
317
318
319             // my vars (def)
320
321         // ctor
322         public Xcls_Button6(Clones _owner )
323         {
324             _this = _owner;
325             this.el = new Gtk.Button();
326
327             // my vars (dec)
328
329             // set gobject values
330             this.el.label = "Merge";
331
332             //listeners
333             this.el.clicked.connect( () =>  {
334             
335                 var rv = _this.reposView;
336                 var rs = _this.reposStore;
337                 var s =rv.el.get_selection();
338                 if (s.count_selected_rows() != 1) {
339                         return;
340                 }
341                 Gtk.TreeIter iter;
342                 Gtk.TreeModel tm;
343                 s.get_selected(out tm, out iter);
344                 GLib.Value val;
345                 tm.get_value(iter, 6, out val);
346                 var git_working_dir = (string)val;
347                 
348                 var repo = GitRepo.singleton().get(git_working_dir);
349                 
350                 // if you hit merge.... in master..
351                 // ignore..
352                 if (repo.currentBranch.name == "master") {
353                         return;
354                 }
355                 MergeBranch.singleton().show(repo.activeTicket, repo);
356                 _this.reposStore.load();
357                 
358              
359                 
360             });
361         }
362
363         // user defined functions
364     }
365
366     public class Xcls_Button7 : Object
367     {
368         public Gtk.Button el;
369         private Clones  _this;
370
371
372             // my vars (def)
373
374         // ctor
375         public Xcls_Button7(Clones _owner )
376         {
377             _this = _owner;
378             this.el = new Gtk.Button();
379
380             // my vars (dec)
381
382             // set gobject values
383             this.el.label = "Switch Branch";
384
385             //listeners
386             this.el.clicked.connect( () => {
387                 
388                 
389              
390                    
391                 
392                 
393             });
394         }
395
396         // user defined functions
397     }
398
399     public class Xcls_Button8 : Object
400     {
401         public Gtk.Button el;
402         private Clones  _this;
403
404
405             // my vars (def)
406
407         // ctor
408         public Xcls_Button8(Clones _owner )
409         {
410             _this = _owner;
411             this.el = new Gtk.Button();
412
413             // my vars (dec)
414
415             // set gobject values
416             this.el.label = "Pull";
417
418             //listeners
419             this.el.clicked.connect( () => {
420                 
421                 
422              
423                    
424                 
425                 
426             });
427         }
428
429         // user defined functions
430     }
431
432     public class Xcls_ok_button : Object
433     {
434         public Gtk.Button el;
435         private Clones  _this;
436
437
438             // my vars (def)
439
440         // ctor
441         public Xcls_ok_button(Clones _owner )
442         {
443             _this = _owner;
444             _this.ok_button = this;
445             this.el = new Gtk.Button();
446
447             // my vars (dec)
448
449             // set gobject values
450             this.el.expand = false;
451             this.el.label = "Close";
452         }
453
454         // user defined functions
455     }
456
457
458     public class Xcls_ScrolledWindow10 : Object
459     {
460         public Gtk.ScrolledWindow el;
461         private Clones  _this;
462
463
464             // my vars (def)
465
466         // ctor
467         public Xcls_ScrolledWindow10(Clones _owner )
468         {
469             _this = _owner;
470             this.el = new Gtk.ScrolledWindow( null, null );
471
472             // my vars (dec)
473
474             // set gobject values
475             this.el.expand = true;
476             this.el.hexpand = true;
477             this.el.shadow_type = Gtk.ShadowType.IN;
478             var child_0 = new Xcls_reposView( _this );
479             child_0.ref();
480             this.el.add (  child_0.el  );
481
482             // init method
483
484             {
485               
486                this.el.set_policy (Gtk.PolicyType.AUTOMATIC, Gtk.PolicyType.AUTOMATIC);
487             }
488         }
489
490         // user defined functions
491     }
492     public class Xcls_reposView : Object
493     {
494         public Gtk.TreeView el;
495         private Clones  _this;
496
497
498             // my vars (def)
499
500         // ctor
501         public Xcls_reposView(Clones _owner )
502         {
503             _this = _owner;
504             _this.reposView = this;
505             this.el = new Gtk.TreeView();
506
507             // my vars (dec)
508
509             // set gobject values
510             this.el.search_column = 0;
511             this.el.enable_grid_lines = Gtk.TreeViewGridLines.HORIZONTAL;
512             var child_0 = new Xcls_reposStore( _this );
513             child_0.ref();
514             this.el.set_model (  child_0.el  );
515             var child_1 = new Xcls_tv_autocommit( _this );
516             child_1.ref();
517             this.el.append_column (  child_1.el  );
518             var child_2 = new Xcls_tv_autopush( _this );
519             child_2.ref();
520             this.el.append_column (  child_2.el  );
521             var child_3 = new Xcls_tv_autobranch( _this );
522             child_3.ref();
523             this.el.append_column (  child_3.el  );
524             var child_4 = new Xcls_tv_repo( _this );
525             child_4.ref();
526             this.el.append_column (  child_4.el  );
527             var child_5 = new Xcls_tv_active_ticket( _this );
528             child_5.ref();
529             this.el.append_column (  child_5.el  );
530             var child_6 = new Xcls_tv_current_branch( _this );
531             child_6.ref();
532             this.el.append_column (  child_6.el  );
533             var child_7 = new Xcls_tv_last_updated( _this );
534             child_7.ref();
535             this.el.append_column (  child_7.el  );
536             var child_8 = new Xcls_tv_all_branches( _this );
537             child_8.ref();
538             this.el.append_column (  child_8.el  );
539
540             // init method
541
542             {
543                 var selection = this.el.get_selection();
544                 selection.set_mode( Gtk.SelectionMode.SINGLE);
545             
546             
547                 var description = new Pango.FontDescription();
548                 description.set_size(10000);
549                 this.el.override_font(description);
550              
551             }
552
553             //listeners
554             this.el.cursor_changed.connect( ()  => {
555               // SEE SELECTION.CHANGED
556               /*
557               
558               return;
559               
560                 if (this.el.get_selection().count_selected_rows() < 1) {
561                     //nothing? - clea it?
562                     return;
563                 }
564                     var ret = {};         
565                 var model = this.get('/changedFilesStore');
566             
567                  var s = this.el.get_selection();
568                  var files = [];
569                 s.selected_foreach(function(model,p,iter) {
570                 
571                    files.push( model.get_value(iter, 0).value.get_string());
572                  
573                 });
574                 this.get('/patchview').showDiff(files); 
575                 //var value = ''+ ret.model.get_value(ret.iter, 1).value.get_string();
576                  //print("OUT?" + value);// id..
577                 // load the list in the right grid..
578                  
579                 return true;
580             */
581             });
582         }
583
584         // user defined functions
585     }
586     public class Xcls_reposStore : Object
587     {
588         public Gtk.ListStore el;
589         private Clones  _this;
590
591
592             // my vars (def)
593
594         // ctor
595         public Xcls_reposStore(Clones _owner )
596         {
597             _this = _owner;
598             _this.reposStore = this;
599             this.el = new Gtk.ListStore( 10,      typeof(string),  // 0 repo
600      typeof(string),  // 1 current branch
601      typeof(string),  // 2 all branch
602      typeof(string),  // 3 updated
603      typeof(bool),   // 4 auto commit
604      typeof(bool),   // 5 auto push
605      typeof(string),   // 6 repopath
606       typeof(string),   // 7 color highlighting?
607        typeof(bool),   // 8 auto branch,
608       typeof(string)   // 9 active Ticket
609        );
610
611             // my vars (dec)
612
613             // set gobject values
614         }
615
616         // user defined functions
617         public void load ()
618         {
619             //this.insert(citer,iter,0);
620             print("getting list");
621             var tr = GitRepo.list();
622             
623             this.el.clear();
624             
625             // fixme .. sort by last updated ...
626             
627             
628             for(var i =0 ; i < tr.length; i++) {
629                     var repo = tr.index(i);
630                     repo.loadBranches();
631                     
632                     Gtk.TreeIter iter;
633                     this.el.append(out iter);
634              
635                 
636                 //print(JSON.stringify(ret,null,4));
637                  //tr[i].getBranches();
638                  //tr[i].getStatus();
639                  //var hi;
640                  //try {
641                      //tr[i].debug=1;
642                  //     hi = tr[i].history('/', 1, 'branch', tr[i].currentBranch.name );
643         //             print(JSON.stringify(hi,null,4));
644                 // } catch(e) { print(e);}
645                   
646                 this.el.set_value(iter, 0,   repo.name );
647                 this.el.set_value( iter, 1, repo.currentBranch.name   );
648                 this.el.set_value( iter, 2,  repo.branchesToString()   );
649         //        this.el.set_value(ret.iter, 2, '' + repo.branches.map(
650         //                        function(e) { return e.name; 
651         //                    }).join(', ') 
652          //        );
653         //        this.el.set_value(iter, 3, '' +  (!hi  ? '??' : hi[0].changed_raw));        
654                 this.el.set_value(iter, 4, repo.is_autocommit() );                
655                 this.el.set_value(iter, 5, repo.is_autopush() );                        
656                 this.el.set_value(iter, 6,  repo.git_working_dir );  
657                 // highlight color.
658                 var cb = repo.currentBranch;
659                 //print(JSON.stringify(cb,null,4));
660                 var col = "#ffffff";
661                 /*
662                 if (cb.lastrev != cb.remoterev) {
663                     col =  '#ff0000';
664                 }
665                 if (tr[i].hasLocalChanges) {
666                     col =  '#0000ff';
667                 }
668                 if  ((cb.lastrev != cb.remoterev) && (tr[i].hasLocalChanges)) {
669                     col =  '#ff00ff';
670                 }
671                 */
672                 this.el.set_value(iter, 7, col  );      
673                 var ticket = repo.activeTicket;
674                 
675                 this.el.set_value(iter, 8, repo.is_auto_branch()  );      
676                 this.el.set_value(iter, 9, ticket == null ? "" : ticket.id  );      
677                 
678                 
679             }     
680             this.el.set_sort_column_id (0, Gtk.SortType.ASCENDING);
681         }
682     }
683
684     public class Xcls_tv_autocommit : Object
685     {
686         public Gtk.TreeViewColumn el;
687         private Clones  _this;
688
689
690             // my vars (def)
691
692         // ctor
693         public Xcls_tv_autocommit(Clones _owner )
694         {
695             _this = _owner;
696             _this.tv_autocommit = this;
697             this.el = new Gtk.TreeViewColumn();
698
699             // my vars (dec)
700
701             // set gobject values
702             this.el.title = "Auto Commit";
703             this.el.min_width = 50;
704             var child_0 = new Xcls_cr_autocommit( _this );
705             child_0.ref();
706             this.el.pack_start (  child_0.el , false );
707
708             // init method
709
710             //    this.items[0].el.set_activatable(true);
711              this.el.add_attribute(_this.cr_autocommit.el , "active", 4 );
712         }
713
714         // user defined functions
715     }
716     public class Xcls_cr_autocommit : Object
717     {
718         public Gtk.CellRendererToggle el;
719         private Clones  _this;
720
721
722             // my vars (def)
723
724         // ctor
725         public Xcls_cr_autocommit(Clones _owner )
726         {
727             _this = _owner;
728             _this.cr_autocommit = this;
729             this.el = new Gtk.CellRendererToggle();
730
731             // my vars (dec)
732
733             // set gobject values
734             this.el.mode = Gtk.CellRendererMode.ACTIVATABLE;
735
736             //listeners
737             this.el.toggled.connect( (self, path)  => {
738               
739                 Gtk.TreeIter iter;
740                 _this.reposStore.el.get_iter_from_string(out iter, path);
741                 
742                 GLib.Value val;
743                 GLib.Value rval;
744                 _this.reposStore.el.get_value(iter, 4, out val);
745                 _this.reposStore.el.get_value(iter, 6, out rval);
746                 
747                 var repopath = (string)rval;
748                 var bval = (bool)val;
749                 _this.reposStore.el.set_value(iter, 4, !bval);
750                 GLib.debug("got repopath? %s", repopath);
751                 
752                 var repo = GitRepo.get(repopath);
753                 repo.set_autocommit(!bval);
754                 
755                 
756                 
757               
758             });
759         }
760
761         // user defined functions
762     }
763
764
765     public class Xcls_tv_autopush : Object
766     {
767         public Gtk.TreeViewColumn el;
768         private Clones  _this;
769
770
771             // my vars (def)
772
773         // ctor
774         public Xcls_tv_autopush(Clones _owner )
775         {
776             _this = _owner;
777             _this.tv_autopush = this;
778             this.el = new Gtk.TreeViewColumn();
779
780             // my vars (dec)
781
782             // set gobject values
783             this.el.title = "Auto Push";
784             this.el.min_width = 50;
785             var child_0 = new Xcls_cr_autopush( _this );
786             child_0.ref();
787             this.el.pack_start (  child_0.el , false );
788
789             // init method
790
791             this.el.add_attribute(_this.cr_autopush.el , "active", 5 );
792             //      this.items[0].el.set_activatable(true);
793         }
794
795         // user defined functions
796     }
797     public class Xcls_cr_autopush : Object
798     {
799         public Gtk.CellRendererToggle el;
800         private Clones  _this;
801
802
803             // my vars (def)
804
805         // ctor
806         public Xcls_cr_autopush(Clones _owner )
807         {
808             _this = _owner;
809             _this.cr_autopush = this;
810             this.el = new Gtk.CellRendererToggle();
811
812             // my vars (dec)
813
814             // set gobject values
815             this.el.mode = Gtk.CellRendererMode.ACTIVATABLE;
816
817             //listeners
818             this.el.toggled.connect( (self, path)  => {
819               
820                 Gtk.TreeIter iter;
821                 _this.reposStore.el.get_iter_from_string(out iter, path);
822                 
823                 GLib.Value val;
824                 GLib.Value rval;
825                 _this.reposStore.el.get_value(iter, 5, out val);
826                 _this.reposStore.el.get_value(iter, 6, out rval);
827                 
828                 var repopath = (string)rval;
829                 var bval = (bool)val;
830                 _this.reposStore.el.set_value(iter, 5, !bval);
831                 var repo = GitRepo.get(repopath);
832                 repo.set_autopush(!bval);
833                 
834                 
835                 
836               
837             });
838         }
839
840         // user defined functions
841     }
842
843
844     public class Xcls_tv_autobranch : Object
845     {
846         public Gtk.TreeViewColumn el;
847         private Clones  _this;
848
849
850             // my vars (def)
851
852         // ctor
853         public Xcls_tv_autobranch(Clones _owner )
854         {
855             _this = _owner;
856             _this.tv_autobranch = this;
857             this.el = new Gtk.TreeViewColumn();
858
859             // my vars (dec)
860
861             // set gobject values
862             this.el.title = "Auto Branch";
863             this.el.min_width = 50;
864             var child_0 = new Xcls_cr_autobranch( _this );
865             child_0.ref();
866             this.el.pack_start (  child_0.el , false );
867
868             // init method
869
870             this.el.add_attribute(_this.cr_autobranch.el , "active", 8 );
871             //      this.items[0].el.set_activatable(true);
872         }
873
874         // user defined functions
875     }
876     public class Xcls_cr_autobranch : Object
877     {
878         public Gtk.CellRendererToggle el;
879         private Clones  _this;
880
881
882             // my vars (def)
883
884         // ctor
885         public Xcls_cr_autobranch(Clones _owner )
886         {
887             _this = _owner;
888             _this.cr_autobranch = this;
889             this.el = new Gtk.CellRendererToggle();
890
891             // my vars (dec)
892
893             // set gobject values
894             this.el.mode = Gtk.CellRendererMode.ACTIVATABLE;
895
896             //listeners
897             this.el.toggled.connect( (self, path)  => {
898               
899                 Gtk.TreeIter iter;
900                 _this.reposStore.el.get_iter_from_string(out iter, path);
901                 
902                 GLib.Value val;
903                 GLib.Value rval;
904                 _this.reposStore.el.get_value(iter, 8, out val);
905                 _this.reposStore.el.get_value(iter, 6, out rval);
906                 
907                 var repopath = (string)rval;
908                 var bval = (bool)val;
909                 _this.reposStore.el.set_value(iter, 8, !bval);
910                 var repo = GitRepo.get(repopath);
911                 repo.set_auto_branch(!bval);
912                 
913                 
914                 
915               
916             });
917         }
918
919         // user defined functions
920     }
921
922
923     public class Xcls_tv_repo : Object
924     {
925         public Gtk.TreeViewColumn el;
926         private Clones  _this;
927
928
929             // my vars (def)
930
931         // ctor
932         public Xcls_tv_repo(Clones _owner )
933         {
934             _this = _owner;
935             _this.tv_repo = this;
936             this.el = new Gtk.TreeViewColumn();
937
938             // my vars (dec)
939
940             // set gobject values
941             this.el.sort_column_id = 0;
942             this.el.title = "Repo";
943             this.el.min_width = 200;
944             this.el.sort_order = Gtk.SortType.ASCENDING;
945             this.el.resizable = true;
946             var child_0 = new Xcls_cr_repo( _this );
947             child_0.ref();
948             this.el.pack_start (  child_0.el , false );
949
950             // init method
951
952             this.el.add_attribute(_this.cr_repo.el , "markup", 0 );
953         }
954
955         // user defined functions
956     }
957     public class Xcls_cr_repo : Object
958     {
959         public Gtk.CellRendererText el;
960         private Clones  _this;
961
962
963             // my vars (def)
964
965         // ctor
966         public Xcls_cr_repo(Clones _owner )
967         {
968             _this = _owner;
969             _this.cr_repo = this;
970             this.el = new Gtk.CellRendererText();
971
972             // my vars (dec)
973
974             // set gobject values
975         }
976
977         // user defined functions
978     }
979
980
981     public class Xcls_tv_active_ticket : Object
982     {
983         public Gtk.TreeViewColumn el;
984         private Clones  _this;
985
986
987             // my vars (def)
988
989         // ctor
990         public Xcls_tv_active_ticket(Clones _owner )
991         {
992             _this = _owner;
993             _this.tv_active_ticket = this;
994             this.el = new Gtk.TreeViewColumn();
995
996             // my vars (dec)
997
998             // set gobject values
999             this.el.title = "Active Ticket";
1000             this.el.min_width = 50;
1001             var child_0 = new Xcls_cr_active_ticket( _this );
1002             child_0.ref();
1003             this.el.pack_start (  child_0.el , false );
1004
1005             // init method
1006
1007             this.el.add_attribute(_this.cr_active_ticket.el , "markup", 9 );
1008         }
1009
1010         // user defined functions
1011     }
1012     public class Xcls_cr_active_ticket : Object
1013     {
1014         public Gtk.CellRendererText el;
1015         private Clones  _this;
1016
1017
1018             // my vars (def)
1019
1020         // ctor
1021         public Xcls_cr_active_ticket(Clones _owner )
1022         {
1023             _this = _owner;
1024             _this.cr_active_ticket = this;
1025             this.el = new Gtk.CellRendererText();
1026
1027             // my vars (dec)
1028
1029             // set gobject values
1030         }
1031
1032         // user defined functions
1033     }
1034
1035
1036     public class Xcls_tv_current_branch : Object
1037     {
1038         public Gtk.TreeViewColumn el;
1039         private Clones  _this;
1040
1041
1042             // my vars (def)
1043
1044         // ctor
1045         public Xcls_tv_current_branch(Clones _owner )
1046         {
1047             _this = _owner;
1048             _this.tv_current_branch = this;
1049             this.el = new Gtk.TreeViewColumn();
1050
1051             // my vars (dec)
1052
1053             // set gobject values
1054             this.el.title = "Current Branch";
1055             this.el.min_width = 50;
1056             var child_0 = new Xcls_cr_current_branch( _this );
1057             child_0.ref();
1058             this.el.pack_start (  child_0.el , false );
1059
1060             // init method
1061
1062             this.el.add_attribute(_this.cr_current_branch.el , "markup", 1 );
1063                  this.el.add_attribute(_this.cr_current_branch.el, "cell-background", 7 );
1064         }
1065
1066         // user defined functions
1067     }
1068     public class Xcls_cr_current_branch : Object
1069     {
1070         public Gtk.CellRendererText el;
1071         private Clones  _this;
1072
1073
1074             // my vars (def)
1075
1076         // ctor
1077         public Xcls_cr_current_branch(Clones _owner )
1078         {
1079             _this = _owner;
1080             _this.cr_current_branch = this;
1081             this.el = new Gtk.CellRendererText();
1082
1083             // my vars (dec)
1084
1085             // set gobject values
1086         }
1087
1088         // user defined functions
1089     }
1090
1091
1092     public class Xcls_tv_last_updated : Object
1093     {
1094         public Gtk.TreeViewColumn el;
1095         private Clones  _this;
1096
1097
1098             // my vars (def)
1099
1100         // ctor
1101         public Xcls_tv_last_updated(Clones _owner )
1102         {
1103             _this = _owner;
1104             _this.tv_last_updated = this;
1105             this.el = new Gtk.TreeViewColumn();
1106
1107             // my vars (dec)
1108
1109             // set gobject values
1110             this.el.title = "Last updated";
1111             this.el.min_width = 50;
1112             var child_0 = new Xcls_cr_last_updated( _this );
1113             child_0.ref();
1114             this.el.pack_start (  child_0.el , false );
1115
1116             // init method
1117
1118             this.el.add_attribute(_this.cr_last_updated.el , "markup", 3 );
1119         }
1120
1121         // user defined functions
1122     }
1123     public class Xcls_cr_last_updated : Object
1124     {
1125         public Gtk.CellRendererText el;
1126         private Clones  _this;
1127
1128
1129             // my vars (def)
1130
1131         // ctor
1132         public Xcls_cr_last_updated(Clones _owner )
1133         {
1134             _this = _owner;
1135             _this.cr_last_updated = this;
1136             this.el = new Gtk.CellRendererText();
1137
1138             // my vars (dec)
1139
1140             // set gobject values
1141         }
1142
1143         // user defined functions
1144     }
1145
1146
1147     public class Xcls_tv_all_branches : Object
1148     {
1149         public Gtk.TreeViewColumn el;
1150         private Clones  _this;
1151
1152
1153             // my vars (def)
1154
1155         // ctor
1156         public Xcls_tv_all_branches(Clones _owner )
1157         {
1158             _this = _owner;
1159             _this.tv_all_branches = this;
1160             this.el = new Gtk.TreeViewColumn();
1161
1162             // my vars (dec)
1163
1164             // set gobject values
1165             this.el.title = "All Branches";
1166             this.el.min_width = 50;
1167             this.el.resizable = false;
1168             var child_0 = new Xcls_cr_all_branches( _this );
1169             child_0.ref();
1170             this.el.pack_start (  child_0.el , false );
1171
1172             // init method
1173
1174             this.el.add_attribute(_this.cr_all_branches.el , "markup", 2 );
1175         }
1176
1177         // user defined functions
1178     }
1179     public class Xcls_cr_all_branches : Object
1180     {
1181         public Gtk.CellRendererText el;
1182         private Clones  _this;
1183
1184
1185             // my vars (def)
1186
1187         // ctor
1188         public Xcls_cr_all_branches(Clones _owner )
1189         {
1190             _this = _owner;
1191             _this.cr_all_branches = this;
1192             this.el = new Gtk.CellRendererText();
1193
1194             // my vars (dec)
1195
1196             // set gobject values
1197         }
1198
1199         // user defined functions
1200     }
1201
1202
1203
1204
1205
1206     public class Xcls_ok_button : Object
1207     {
1208         public Gtk.Button el;
1209         private Clones  _this;
1210
1211
1212             // my vars (def)
1213
1214         // ctor
1215         public Xcls_ok_button(Clones _owner )
1216         {
1217             _this = _owner;
1218             _this.ok_button = this;
1219             this.el = new Gtk.Button();
1220
1221             // my vars (dec)
1222
1223             // set gobject values
1224             this.el.expand = false;
1225             this.el.label = "Close";
1226         }
1227
1228         // user defined functions
1229     }
1230
1231 }