0
0
mirror of https://github.com/vim/vim.git synced 2025-09-23 03:43:49 -04:00

patch 7.4.1570

Problem:    There is no way to avoid the message when editing a file.
Solution:   Add the "F" flag to 'shortmess'. (Shougo, closes #686)
This commit is contained in:
Bram Moolenaar
2016-03-15 15:09:29 +01:00
parent e27dba499a
commit 426dd02195
5 changed files with 16 additions and 4 deletions

View File

@@ -6534,6 +6534,8 @@ A jump table for the options with a short description can be found at |Q_op|.
"-- XXX completion (YYY)", "match 1 of 2", "The only match",
"Pattern not found", "Back at original", etc.
q use "recording" instead of "recording @a"
F don't give the file info when editing a file, like `:silent`
was used for the command
This gives you the opportunity to avoid that a change between buffers
requires you to hit <Enter>, but still gives as useful a message as

View File

@@ -139,14 +139,19 @@ open_buffer(
#endif
)
{
int old_msg_silent = msg_silent;
#ifdef FEAT_NETBEANS_INTG
int oldFire = netbeansFireChanges;
netbeansFireChanges = 0;
#endif
if (shortmess(SHM_FILEINFO))
msg_silent = 1;
retval = readfile(curbuf->b_ffname, curbuf->b_fname,
(linenr_T)0, (linenr_T)0, (linenr_T)MAXLNUM, eap,
flags | READ_NEW);
msg_silent = old_msg_silent;
#ifdef FEAT_NETBEANS_INTG
netbeansFireChanges = oldFire;
#endif

View File

@@ -2605,6 +2605,7 @@ ex_file(exarg_T *eap)
return;
}
/* print full file name if :cd used */
if (!shortmess(SHM_FILEINFO))
fileinfo(FALSE, FALSE, eap->forceit);
}
@@ -3884,6 +3885,7 @@ do_ecmd(
msg_scroll = msg_scroll_save;
msg_scrolled_ign = TRUE;
if (!shortmess(SHM_FILEINFO))
fileinfo(FALSE, TRUE, FALSE);
msg_scrolled_ign = FALSE;

View File

@@ -214,7 +214,8 @@
#define SHM_INTRO 'I' /* intro messages */
#define SHM_COMPLETIONMENU 'c' /* completion menu messages */
#define SHM_RECORDING 'q' /* short recording message */
#define SHM_ALL "rmfixlnwaWtToOsAIcq" /* all possible flags for 'shm' */
#define SHM_FILEINFO 'F' /* no file info messages */
#define SHM_ALL "rmfixlnwaWtToOsAIcqF" /* all possible flags for 'shm' */
/* characters for p_go: */
#define GO_ASEL 'a' /* autoselect */

View File

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