summaryrefslogtreecommitdiff
path: root/lib/blame.tcl
diff options
context:
space:
mode:
authorShawn O. Pearce <spearce@spearce.org>2007-06-02 01:59:29 (GMT)
committerShawn O. Pearce <spearce@spearce.org>2007-06-06 05:26:47 (GMT)
commit79c50bf3ee1e0fb5c257ed6f6680cae726a4c412 (patch)
tree8e72a8d49cacf46e0aede29e18ad38d9b651a8c8 /lib/blame.tcl
parent669fbc3d09b259bb3bc3bd2ab126ceb28db61b16 (diff)
downloadgit-79c50bf3ee1e0fb5c257ed6f6680cae726a4c412.zip
git-79c50bf3ee1e0fb5c257ed6f6680cae726a4c412.tar.gz
git-79c50bf3ee1e0fb5c257ed6f6680cae726a4c412.tar.bz2
git-gui: Show original filename in blame tooltip
If we have two commits right next to each other in the final file and they were kept as different blocks in the leftmost column then its probably because the original filename was different. To help the user know where they are digging into when they click on that link we now show the original file in the tooltip, but to save space we do so only if the original file is not the same as the file we are currently viewing. Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
Diffstat (limited to 'lib/blame.tcl')
-rw-r--r--lib/blame.tcl7
1 files changed, 7 insertions, 0 deletions
diff --git a/lib/blame.tcl b/lib/blame.tcl
index 33d5204..bd8e631 100644
--- a/lib/blame.tcl
+++ b/lib/blame.tcl
@@ -805,6 +805,13 @@ method _open_tooltip {cur_w} {
$author_name $author_email $author_time
$summary"
+ set file $line_file($lno)
+ if {$file ne $path} {
+ append tooltip_text "
+
+Original File: $file"
+ }
+
if {$tooltip_wm ne "$cur_w.tooltip"} {
_hide_tooltip $this