author | Paul Mackerras <paulus@samba.org> | |
Mon, 13 Aug 2007 06:17:33 +0000 (16:17 +1000) | ||
committer | Paul Mackerras <paulus@samba.org> | |
Mon, 13 Aug 2007 06:17:33 +0000 (16:17 +1000) |
1 | 2 | |||
---|---|---|---|---|
gitk | patch | | diff1 | | diff2 | | blob | history |
diff --cc gitk
index c0cdd625f220f3b71d5ce4f3aba6871842ef2a3a,57617d58b070892a730e956e82a2f382c28659e2..f5b2da3a88f831b6188d3f994313cf4c2253bf2d
+++ b/gitk
global idinlist rowchk rowrangelist
set idlist [lindex $rowidlist $row]
- set offs [lindex $rowoffsets $row]
while {$row < $endrow} {
set id [lindex $displayorder $row]
- set oldolds {}
- set newolds {}
- set olds [lindex $parentlist $row]
- foreach p $olds {
- if {![info exists idinlist($p)]} {
- lappend newolds $p
- } elseif {!$idinlist($p)} {
- lappend oldolds $p
- set nev [expr {[llength $idlist] - $maxwidth + 1}]
- foreach p [lindex $parentlist $row] {
- if {![info exists idinlist($p)] || !$idinlist($p)} {
- incr nev
-- }
- set idinlist($p) 1
-- }
- set nev [expr {[llength $idlist] + [llength $newolds]
- + [llength $oldolds] - $maxwidth + 1}]
- if {1 || $nev > 0} {
- if {$nev > 0} {
++ if {1} {
if {!$last &&
$row + $uparrowlen + $mingaplen >= $commitidx($curview)} break
for {set x [llength $idlist]} {[incr x -1] >= 0} {} {
set idinlist($i) 0
set rm1 [expr {$row - 1}]
lappend idrowranges($i) [lindex $displayorder $rm1]
- #if {[incr nev -1] <= 0} break
- if {[incr nev -1] <= 0} break
continue
}
- set rowchk($id) [expr {$row + $r}]
+ set rowchk($i) [expr {$row + $r}]
}
}
lset rowidlist $row $idlist
- lset rowoffsets $row $offs
}
+ set oldolds {}
+ set newolds {}
+ foreach p [lindex $parentlist $row] {
+ if {![info exists idinlist($p)]} {
+ lappend newolds $p
+ } elseif {!$idinlist($p)} {
+ lappend oldolds $p
+ }
+ set idinlist($p) 1
+ }
set col [lsearch -exact $idlist $id]
if {$col < 0} {
- set col [llength $idlist]
- lappend idlist $id
+ set col [idcol $idlist $id]
+ set idlist [linsert $idlist $col $id]
lset rowidlist $row $idlist
- set z {}
if {$children($curview,$id) ne {}} {
- set z [expr {[llength [lindex $rowidlist [expr {$row-1}]]] - $col}]
unset idinlist($id)
- }
- lappend offs $z
- lset rowoffsets $row $offs
- if {$z ne {}} {
- makeuparrow $id $col $row $z
+ makeuparrow $id $row $col
}
} else {
unset idinlist($id)