about summary refs log tree commit diff
diff options
context:
space:
mode:
authorSven Wischnowsky <wischnow@users.sourceforge.net>2000-06-14 06:54:44 +0000
committerSven Wischnowsky <wischnow@users.sourceforge.net>2000-06-14 06:54:44 +0000
commit53f5cc9465c0a0d3b7ae125a318fb8a0b7373908 (patch)
treec7a20497d450834b2e9e35122d40edd60aad3134
parentf4c3c3743dbcb55b7fcaa7311a499c5d6a343aba (diff)
downloadzsh-53f5cc9465c0a0d3b7ae125a318fb8a0b7373908.tar.gz
zsh-53f5cc9465c0a0d3b7ae125a318fb8a0b7373908.tar.xz
zsh-53f5cc9465c0a0d3b7ae125a318fb8a0b7373908.zip
better fix for menu selection on dumb terminal (11885?)
-rw-r--r--ChangeLog5
-rw-r--r--Src/Zle/complist.c6
2 files changed, 8 insertions, 3 deletions
diff --git a/ChangeLog b/ChangeLog
index 164e7fe20..68e9da60a 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2000-06-14  Sven Wischnowsky  <wischnow@zsh.org>
+
+	* 11885: Src/Zle/complist.c: better fix for menu selection on dumb 
+	terminal
+	
 2000-06-13  Clint Adams  <schizo@debian.org>
 
 	* 11882: Completion/Debian/_dpkg: more intelligence in
diff --git a/Src/Zle/complist.c b/Src/Zle/complist.c
index 81c6c76a8..f4542ee36 100644
--- a/Src/Zle/complist.c
+++ b/Src/Zle/complist.c
@@ -1493,6 +1493,8 @@ complistmatches(Hookdef dummy, Chdata dat)
 
     amatches = dat->matches;
 
+    noselect = 0;
+
     if ((minfo.asked == 2 && mselect < 0) || nlnct >= lines) {
 	showinglist = 0;
 	amatches = oamatches;
@@ -1629,8 +1631,6 @@ domenuselect(Hookdef dummy, Chdata dat)
     int space, lbeg = 0, step = 1, wrap, pl = nlnct, broken = 0, first = 1;
     char *s;
 
-    if (!mtab)
-	return 0;
     if (fdat || (dummy && (!(s = getsparam("MENUSELECT")) ||
 			   (dat && dat->num < atoi(s))))) {
 	if (fdat) {
@@ -1651,7 +1651,7 @@ domenuselect(Hookdef dummy, Chdata dat)
     mhasstat = (mstatus && *mstatus);
     fdat = dat;
     selectlocalmap(mskeymap);
-    noselect = 0;
+    noselect = 1;
     while ((menuacc &&
 	    !hasbrpsfx(*(minfo.cur), minfo.prebr, minfo.postbr)) ||
 	   (((*minfo.cur)->flags & (CMF_NOLIST | CMF_MULT)) &&