vim-patch:7.4.392

Problem:    Not easy to detect type of command line window.
Solution:   Add the getcmdwintype() function. (Jacob Niehus)

https://code.google.com/p/vim/source/detail?r=v7-4-392
This commit is contained in:
Shougo Matsushita 2014-09-18 20:44:36 +09:00
parent a447160a6c
commit b57d6ef09a
2 changed files with 13 additions and 1 deletions

View File

@ -6388,6 +6388,7 @@ static struct fst {
{"getcmdline", 0, 0, f_getcmdline},
{"getcmdpos", 0, 0, f_getcmdpos},
{"getcmdtype", 0, 0, f_getcmdtype},
{"getcmdwintype", 0, 0, f_getcmdwintype},
{"getcurpos", 0, 0, f_getcurpos},
{"getcwd", 0, 0, f_getcwd},
{"getfontname", 0, 1, f_getfontname},
@ -9155,6 +9156,17 @@ static void f_getcmdtype(typval_T *argvars, typval_T *rettv)
rettv->vval.v_string[0] = get_cmdline_type();
}
/*
* "getcmdwintype()" function
*/
static void f_getcmdwintype(typval_T *argvars, typval_T *rettv)
{
rettv->v_type = VAR_STRING;
rettv->vval.v_string = NULL;
rettv->vval.v_string = xmallocz(1);
rettv->vval.v_string[0] = cmdwin_type;
}
/*
* "getcwd()" function
*/

View File

@ -203,7 +203,7 @@ static int included_patches[] = {
//395,
//394,
//393,
//392,
392,
//391,
//390,
//389,