Skip to content

Commit 379e0bd

Browse files
authored
Merge pull request #610 from hashue/feat/support-cmdheight
fix not display cmdwin when `cmdheight = 0`
2 parents 3ce448c + 900f086 commit 379e0bd

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

autoload/ctrlp.vim

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -330,6 +330,7 @@ fu! s:Open()
330330
endf
331331

332332
fu! s:Close()
333+
if &cmdheight != 0 | set cmdheight=0 |en
333334
cal s:async_glob_abort(0)
334335
cal s:buffunc(0)
335336
if winnr('$') == 1
@@ -2845,6 +2846,8 @@ fu! ctrlp#init(type, ...)
28452846
if shouldExitSingle && s:ExitIfSingleCandidate()
28462847
retu 0
28472848
en
2849+
2850+
if &cmdheight == 0 | set cmdheight=1 | en
28482851
cal s:BuildPrompt(1)
28492852
if s:keyloop | cal s:KeyLoop() | en
28502853
retu 1

0 commit comments

Comments
 (0)