threads / patch / 26429

patchgit-gui: scroll down to default selection for push dialog

Subject: [PATCH] git-gui: scroll down to default selection for push dialog

## tl;dr

One message between Feb 6, 2011 and Feb 6, 2011. Diffs are folded; open one to read it.

replies: 0people: 1as markdown or json

Heiko Voigt· Feb 6, 2011, 17:04 UTC · lore

If the list of remote/local branches is very long its inconvenient to scroll down and find the selected branch. This patch makes the widget automatically scroll down so its shown on the top.

Signed-off-by: Heiko Voigt <hvoigt@hvoigt.net>
---
Note: Please also apply with 'git am -p2'
 git-gui/lib/transport.tcl |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
Show changes to git-gui/lib/transport.tcl +1 −0
diff --git a/git-gui/lib/transport.tcl b/git-gui/lib/transport.tcl
index e4e1add..6478efa 100644
--- a/git-gui/lib/transport.tcl
+++ b/git-gui/lib/transport.tcl
@@ -211,6 +211,7 @@ proc do_push_anywhere {} {
 		$w.source.l insert end $h
 		if {$h eq $current_branch} {
 			$w.source.l select set end
+			$w.source.l yview end
 		}
 	}
 	pack $w.source.l -side left -fill both -expand 1
-- 
1.7.4.34.gd2cb1

← back to recent threads