Kiln » TortoiseHg » TortoiseHg
Clone URL:  
Pushed to one repository · View In Graph Contained in 1.0, 1.0.1, and 1.0.2

history: gather column names to treeview.py

Changeset 1640dba0fc6b

Parent a9c8a7d10b44

by Yuki KODAMA

Changes to 2 files · Browse files at 1640dba0fc6b Showing diff from parent a9c8a7d10b44 Diff from another changeset...

 
21
22
23
 
24
25
26
 
406
407
408
409
410
 
 
411
412
413
 
573
574
575
576
 
577
578
579
 
633
634
635
636
 
637
638
639
 
656
657
658
659
 
660
661
662
663
664
665
 
666
667
668
 
21
22
23
24
25
26
27
 
407
408
409
 
 
410
411
412
413
414
 
574
575
576
 
577
578
579
580
 
634
635
636
 
637
638
639
640
 
657
658
659
 
660
661
662
663
664
 
 
665
666
667
668
@@ -21,6 +21,7 @@
 from tortoisehg.util import hglib    from tortoisehg.hgtk.logview.treeview import TreeView as LogTreeView +from tortoisehg.hgtk.logview.treeview import COLS as DEFAULT_COLS    from tortoisehg.hgtk import gdialog, gtklib, hgcmd, gorev, thgstrip  from tortoisehg.hgtk import backout, status, hgemail, tagadd, update, merge @@ -406,8 +407,8 @@
  column('tag', _('Tags'))     model = gtk.ListStore( - gobject.TYPE_BOOLEAN, - gobject.TYPE_STRING, + gobject.TYPE_BOOLEAN, + gobject.TYPE_STRING,   gobject.TYPE_STRING,   gobject.TYPE_STRING)   @@ -573,7 +574,7 @@
  self.syncbox.set_property('visible', self.show_syncbar)   self.syncbox.set_no_show_all(True)   - for col in ('rev', 'date', 'id', 'revhex', 'branch', 'utc', 'age', 'tag'): + for col in [col for col in DEFAULT_COLS.split() if col != 'graph']:   if col in self.showcol:   self.graphview.set_property(col+'-column-visible',   self.showcol[col]) @@ -633,7 +634,7 @@
  settings['show-syncbar'] = self.show_syncbar   settings['graphcol'] = self.graphcol   settings['compactgraph'] = self.compactgraph - for col in ('rev', 'date', 'id', 'revhex', 'branch', 'utc', 'age', 'tag'): + for col in [col for col in DEFAULT_COLS.split() if col != 'graph']:   vis = self.graphview.get_property(col+'-column-visible')   settings['glog-vis-'+col] = vis   settings['filter-mode'] = self.filtercombo.get_active() @@ -656,13 +657,12 @@
  self.graphcol = settings.get('graphcol', True)   self.compactgraph = settings.get('compactgraph', False)   self.showcol = {} - for col in ('rev', 'date', 'id', 'revhex', 'branch', 'utc', 'age', 'tag'): + for col in [col for col in DEFAULT_COLS.split() if col != 'graph']:   key = 'glog-vis-'+col   if key in settings:   self.showcol[col] = settings[key]   self.filter_mode = settings.get('filter-mode', 1) - default_co = 'graph rev id revhex branch msg user date utc age tag' - self.column_order = settings.get('column-order', default_co) + self.column_order = settings.get('column-order', DEFAULT_COLS)     def show_toolbar_on_start(self):   return self.show_toolbar
 
27
28
29
 
30
31
32
 
523
524
525
526
527
 
528
529
530
 
27
28
29
30
31
32
33
 
524
525
526
 
 
527
528
529
530
@@ -27,6 +27,7 @@
 from tortoisehg.hgtk.logview.graphcell import CellRendererGraph  from tortoisehg.hgtk.logview.revgraph import *   +COLS = 'graph rev id revhex branch msg user date utc age tag'    class TreeView(gtk.ScrolledWindow):   @@ -523,8 +524,7 @@
  col.add_attribute(cell, "text", treemodel.TAGS)   col.add_attribute(cell, "foreground", treemodel.FGCOLOR)   - cols = 'graph rev id revhex branch msg user date utc age tag' - self.columns = cols.split() + self.columns = COLS.split()     # append columns   for cn in self.columns: