提交 0a462d67 编写于 作者: S Shawn O. Pearce

git-gui: Disable pull menu items when the index is locked.

If we have the index locked then no pull command is allowed to proceed
(as it would fail to get the index lock itself).  So disable the pull
menu items when we are doing any index based operations.
Signed-off-by: NShawn O. Pearce <spearce@spearce.org>
上级 2bc5b348
......@@ -932,7 +932,7 @@ proc populate_remote_menu {m pfx op} {
}
proc populate_pull_menu {m} {
global gitdir repo_config all_remotes mainfont
global gitdir repo_config all_remotes mainfont disable_on_lock
foreach remote $all_remotes {
set rb {}
......@@ -961,6 +961,8 @@ proc populate_pull_menu {m} {
-label "Branch $rb_short from $remote..." \
-command [list pull_remote $remote $rb] \
-font $mainfont
lappend disable_on_lock \
[list $m entryconf [$m index last] -state]
}
}
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册