vim-patch:7.4.418

Problem:    When leaving ":append" the cursor shape is like in Insert mode.
            (Jacob Niehus)
Solution:   Do not have State set to INSERT when calling getline().

https://code.google.com/p/vim/source/detail?r=v7-4-418
This commit is contained in:
Scott Prager
2014-10-16 15:55:54 -04:00
parent 0a2d9fa8c8
commit f2e5851dd9
2 changed files with 8 additions and 2 deletions

View File

@@ -3183,10 +3183,16 @@ void ex_append(exarg_T *eap)
if (*p != NUL) if (*p != NUL)
++p; ++p;
eap->nextcmd = p; eap->nextcmd = p;
} else } else {
// Set State to avoid the cursor shape to be set to INSERT mode
// when getline() returns.
int save_State = State;
State = CMDLINE;
theline = eap->getline( theline = eap->getline(
eap->cstack->cs_looplevel > 0 ? -1 : eap->cstack->cs_looplevel > 0 ? -1 :
NUL, eap->cookie, indent); NUL, eap->cookie, indent);
State = save_State;
}
lines_left = Rows - 1; lines_left = Rows - 1;
if (theline == NULL) if (theline == NULL)
break; break;

View File

@@ -214,7 +214,7 @@ static int included_patches[] = {
//421, //421,
//420 NA //420 NA
//419, //419,
//418, 418,
//417, //417,
//416, //416,
//415, //415,