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