Kiln » TortoiseHg » TortoiseHg
Clone URL:  
Pushed to one repository · View In Graph Contained in 1.9, 1.9.1, and 1.9.2

repomodel: move graph into separate Graph column

Changeset 184436d64bd0

Parent cdd7989cc564

by George Marrows

Changes to one file · Browse files at 184436d64bd0 Showing diff from parent cdd7989cc564 Diff from another changeset...

 
79
80
81
 
82
83
84
 
129
130
131
132
133
 
 
134
135
136
 
320
321
322
323
 
324
325
326
 
79
80
81
82
83
84
85
 
130
131
132
 
 
133
134
135
136
137
 
321
322
323
 
324
325
326
327
@@ -79,6 +79,7 @@
 # XXX maybe it's time to make these methods of the model...  # in following lambdas, ctx is a hg changectx  _columnmap = {'ID': lambda model, ctx, gnode: ctx.rev() is not None and str(ctx.rev()) or "", + 'Graph': lambda model, ctx, gnode: "",   'Log': getlog,   'Author': lambda model, ctx, gnode: tounicode(   templatefilters.person(ctx.user())), @@ -129,8 +130,8 @@
  """   Model used for displaying the revisions of a Hg *local* repository   """ - _allcolumns = ('ID', 'Branch', 'Log', 'Author', 'Date', 'Tags',) - _columns = ('ID', 'Branch', 'Log', 'Author', 'Date', 'Tags',) + _allcolumns = ('ID', 'Branch', 'Graph', 'Log', 'Author', 'Date', 'Tags',) + _columns = ('ID', 'Branch', 'Graph', 'Log', 'Author', 'Date', 'Tags',)   _stretchs = {'Log': 1, }   _getcolumns = "getChangelogColumns"   @@ -320,7 +321,7 @@
  if column == 'Branch': #branch   return QVariant(QColor(self.namedbranch_color(ctx.branch())))   elif role == Qt.DecorationRole: - if column == 'Log': + if column == 'Graph':   w = self.col2x(gnode.cols) + 10   h = self.rowheight