mirror of
https://github.com/vim/vim.git
synced 2026-05-28 00:21:37 +02:00
patch 9.1.2080: W23/W24 messsage appears on :reg
Problem: W23/W24 messsage appears on :reg
(Coacher)
Solution: Silence message when using :reg command
(Foxe Chen)
fixes: #19161
closes: #19166
Co-authored-by: h_east <h.east.727@gmail.com>
Signed-off-by: Foxe Chen <chen.foxe@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
This commit is contained in:
committed by
Christian Brabandt
parent
300ea1133f
commit
f3961074fb
@@ -2142,3 +2142,6 @@ EXTERN int allow_osc_key INIT(= 0);
|
||||
EXTERN redraw_listener_T *redraw_listeners INIT(= NULL);
|
||||
EXTERN bool inside_redraw_on_start_cb INIT(= false);
|
||||
#endif
|
||||
|
||||
// If greater than zero, then silence the W23/W24 warning.
|
||||
EXTERN int silence_w23_w24_msg INIT( = 0);
|
||||
|
||||
+1
-1
@@ -4207,7 +4207,7 @@ msg_advance(int col)
|
||||
void
|
||||
msg_warn_missing_clipboard(void)
|
||||
{
|
||||
if (!global_busy && !did_warn_clipboard)
|
||||
if (!global_busy && !did_warn_clipboard && silence_w23_w24_msg == 0)
|
||||
{
|
||||
#ifdef FEAT_CLIPBOARD
|
||||
msg(_("W23: Clipboard register not available, using register 0"));
|
||||
|
||||
@@ -2446,6 +2446,7 @@ ex_display(exarg_T *eap)
|
||||
int type;
|
||||
string_T insert;
|
||||
|
||||
silence_w23_w24_msg++;
|
||||
if (arg != NULL && *arg == NUL)
|
||||
arg = NULL;
|
||||
attr = HL_ATTR(HLF_8);
|
||||
@@ -2609,6 +2610,7 @@ ex_display(exarg_T *eap)
|
||||
#ifdef FEAT_CLIPBOARD_PROVIDER
|
||||
dec_clip_provider();
|
||||
#endif
|
||||
silence_w23_w24_msg--;
|
||||
}
|
||||
|
||||
/*
|
||||
|
||||
@@ -734,6 +734,8 @@ static char *(features[]) =
|
||||
|
||||
static int included_patches[] =
|
||||
{ /* Add new patch number below this line */
|
||||
/**/
|
||||
2080,
|
||||
/**/
|
||||
2079,
|
||||
/**/
|
||||
|
||||
Reference in New Issue
Block a user