summaryrefslogtreecommitdiff
path: root/gitk
diff options
context:
space:
mode:
authorPaul Mackerras <paulus@samba.org>2012-09-12 12:34:24 (GMT)
committerPaul Mackerras <paulus@samba.org>2012-09-12 12:34:24 (GMT)
commit5be4d354d9031bee65406608bfbdfc0fbc85abdb (patch)
tree9ef9d4c7249d9515b85f0f158367e40a5ee52918 /gitk
parent0ae103574e5411be107c31a3390884f65fbaa0ef (diff)
parent587277fea3bf3bfc4302480178bd88a277a69f05 (diff)
downloadgit-5be4d354d9031bee65406608bfbdfc0fbc85abdb.zip
git-5be4d354d9031bee65406608bfbdfc0fbc85abdb.tar.gz
git-5be4d354d9031bee65406608bfbdfc0fbc85abdb.tar.bz2
Merge branch 'da/gitk-reload-tag-contents' of git://github.com/gitster/git
to get two commits from David Aguilar.
Diffstat (limited to 'gitk')
-rwxr-xr-xgitk13
1 files changed, 7 insertions, 6 deletions
diff --git a/gitk b/gitk
index 1f412bb..d93bd99 100755
--- a/gitk
+++ b/gitk
@@ -10599,7 +10599,7 @@ proc movedhead {hid head} {
}
proc changedrefs {} {
- global cached_dheads cached_dtags cached_atags
+ global cached_dheads cached_dtags cached_atags cached_tagcontent
global arctags archeads arcnos arcout idheads idtags
foreach id [concat [array names idheads] [array names idtags]] {
@@ -10611,6 +10611,7 @@ proc changedrefs {} {
}
}
}
+ catch {unset cached_tagcontent}
catch {unset cached_dtags}
catch {unset cached_atags}
catch {unset cached_dheads}
@@ -10663,7 +10664,7 @@ proc listrefs {id} {
}
proc showtag {tag isnew} {
- global ctext tagcontents tagids linknum tagobjid
+ global ctext cached_tagcontent tagids linknum tagobjid
if {$isnew} {
addtohistory [list showtag $tag 0] savectextpos
@@ -10672,13 +10673,13 @@ proc showtag {tag isnew} {
clear_ctext
settabs 0
set linknum 0
- if {![info exists tagcontents($tag)]} {
+ if {![info exists cached_tagcontent($tag)]} {
catch {
- set tagcontents($tag) [exec git cat-file tag $tag]
+ set cached_tagcontent($tag) [exec git cat-file tag $tag]
}
}
- if {[info exists tagcontents($tag)]} {
- set text $tagcontents($tag)
+ if {[info exists cached_tagcontent($tag)]} {
+ set text $cached_tagcontent($tag)
} else {
set text "[mc "Tag"]: $tag\n[mc "Id"]: $tagids($tag)"
}