0
0
mirror of https://github.com/vim/vim.git synced 2025-07-25 10:54:51 -04:00

updated for version 7.3.167

Problem:    When using the internal grep QuickFixCmdPost is not triggered.
            (Yukihiro Nakadaira)
Solution:   Change the place where autocommands are triggered.
This commit is contained in:
Bram Moolenaar 2011-04-28 17:27:09 +02:00
parent f844147747
commit d88e02def5
2 changed files with 16 additions and 10 deletions

View File

@ -2742,6 +2742,13 @@ ex_make(eap)
#ifdef FEAT_AUTOCMD #ifdef FEAT_AUTOCMD
char_u *au_name = NULL; char_u *au_name = NULL;
/* Redirect ":grep" to ":vimgrep" if 'grepprg' is "internal". */
if (grep_internal(eap->cmdidx))
{
ex_vimgrep(eap);
return;
}
switch (eap->cmdidx) switch (eap->cmdidx)
{ {
case CMD_make: au_name = (char_u *)"make"; break; case CMD_make: au_name = (char_u *)"make"; break;
@ -2763,13 +2770,6 @@ ex_make(eap)
} }
#endif #endif
/* Redirect ":grep" to ":vimgrep" if 'grepprg' is "internal". */
if (grep_internal(eap->cmdidx))
{
ex_vimgrep(eap);
return;
}
if (eap->cmdidx == CMD_lmake || eap->cmdidx == CMD_lgrep if (eap->cmdidx == CMD_lmake || eap->cmdidx == CMD_lgrep
|| eap->cmdidx == CMD_lgrepadd) || eap->cmdidx == CMD_lgrepadd)
wp = curwin; wp = curwin;
@ -3057,10 +3057,14 @@ ex_vimgrep(eap)
switch (eap->cmdidx) switch (eap->cmdidx)
{ {
case CMD_vimgrep: au_name = (char_u *)"vimgrep"; break; case CMD_vimgrep: au_name = (char_u *)"vimgrep"; break;
case CMD_lvimgrep: au_name = (char_u *)"lvimgrep"; break; case CMD_lvimgrep: au_name = (char_u *)"lvimgrep"; break;
case CMD_vimgrepadd: au_name = (char_u *)"vimgrepadd"; break; case CMD_vimgrepadd: au_name = (char_u *)"vimgrepadd"; break;
case CMD_lvimgrepadd: au_name = (char_u *)"lvimgrepadd"; break; case CMD_lvimgrepadd: au_name = (char_u *)"lvimgrepadd"; break;
case CMD_grep: au_name = (char_u *)"grep"; break;
case CMD_lgrep: au_name = (char_u *)"lgrep"; break;
case CMD_grepadd: au_name = (char_u *)"grepadd"; break;
case CMD_lgrepadd: au_name = (char_u *)"lgrepadd"; break;
default: break; default: break;
} }
if (au_name != NULL) if (au_name != NULL)

View File

@ -714,6 +714,8 @@ static char *(features[]) =
static int included_patches[] = static int included_patches[] =
{ /* Add new patch number below this line */ { /* Add new patch number below this line */
/**/
167,
/**/ /**/
166, 166,
/**/ /**/