diff options
author | Sven Wischnowsky <wischnow@users.sourceforge.net> | 2000-06-28 07:29:59 +0000 |
---|---|---|
committer | Sven Wischnowsky <wischnow@users.sourceforge.net> | 2000-06-28 07:29:59 +0000 |
commit | 0334b4df7cfd728cd8b9480872fbbfcb6029d1e6 (patch) | |
tree | f4f76e56ecb0deaae771129fd7bd512a47dee3a9 /Src/Zle/complist.c | |
parent | f889ebfaa3f8d70f5a0e00153bd1b91a8d6c0131 (diff) | |
download | zsh-0334b4df7cfd728cd8b9480872fbbfcb6029d1e6.tar.gz zsh-0334b4df7cfd728cd8b9480872fbbfcb6029d1e6.tar.xz zsh-0334b4df7cfd728cd8b9480872fbbfcb6029d1e6.zip |
make a-a-i-n-h in menu selection work with one match; better undo behaviour for menu selection (12093)
Diffstat (limited to 'Src/Zle/complist.c')
-rw-r--r-- | Src/Zle/complist.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/Src/Zle/complist.c b/Src/Zle/complist.c index 75a23f0e5..9159326f3 100644 --- a/Src/Zle/complist.c +++ b/Src/Zle/complist.c @@ -1782,11 +1782,15 @@ domenuselect(Hookdef dummy, Chdata dat) menucmp = menuacc = hasoldlist = 0; minfo.cur = NULL; fixsuffix(); + handleundo(); validlist = 0; amatches = pmatches = lastmatches = NULL; invalidate_list(); + iforcemenu = 1; menucomplete(zlenoargs); - if (dat->num < 2 || !minfo.cur || !*(minfo.cur)) { + iforcemenu = 0; + + if (dat->num < 1 || !minfo.cur || !*(minfo.cur)) { noselect = clearlist = listshown = 1; onlyexpl = 0; zrefresh(); @@ -1821,6 +1825,7 @@ domenuselect(Hookdef dummy, Chdata dat) s->origcs = origcs; s->origll = origll; accept_last(); + handleundo(); do_menucmp(0); mselect = (*(minfo.cur))->gnum; @@ -1852,6 +1857,7 @@ domenuselect(Hookdef dummy, Chdata dat) if (!u) break; + handleundo(); cs = 0; foredel(ll); spaceinline(l = strlen(u->line)); |