summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 561d038)
raw | patch | inline | side by side (parent: 561d038)
author | OGAWA Hirofumi <hirofumi@mail.parknet.co.jp> | |
Wed, 27 Sep 2006 03:32:19 +0000 (12:32 +0900) | ||
committer | Paul Mackerras <paulus@samba.org> | |
Thu, 19 Oct 2006 00:10:11 +0000 (10:10 +1000) |
The current nextfile() jumps to last hunk, but I think this is not
intention, probably, it's forgetting to add "break;". And this
patch also adds prevfile(), it jumps to previous hunk.
Signed-off-by: OGAWA Hirofumi <hirofumi@mail.parknet.co.jp>
Signed-off-by: Paul Mackerras <paulus@samba.org>
intention, probably, it's forgetting to add "break;". And this
patch also adds prevfile(), it jumps to previous hunk.
Signed-off-by: OGAWA Hirofumi <hirofumi@mail.parknet.co.jp>
Signed-off-by: Paul Mackerras <paulus@samba.org>
gitk | patch | blob | history |
index ebbeac63aaac66c3ffef53c1d66836c11d22ddbf..ab383b3ad29cea5c7c45a8f757941acbc3abaf33 100755 (executable)
--- a/gitk
+++ b/gitk
}
}
+proc prevfile {} {
+ global difffilestart ctext
+ set prev [lindex $difffilestart 0]
+ set here [$ctext index @0,0]
+ foreach loc $difffilestart {
+ if {[$ctext compare $loc >= $here]} {
+ $ctext yview $prev
+ return
+ }
+ set prev $loc
+ }
+ $ctext yview $prev
+}
+
proc nextfile {} {
global difffilestart ctext
set here [$ctext index @0,0]
foreach loc $difffilestart {
if {[$ctext compare $loc > $here]} {
$ctext yview $loc
+ return
}
}
}