diff options
author | Bram Moolenaar <Bram@vim.org> | 2019-10-17 23:00:07 +0200 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2019-10-17 23:00:07 +0200 |
commit | a1cb1d1dce14dd005797590721f1bcd0e7c3b35f (patch) | |
tree | be364e198e623b25d59e58d205e598fd954d3f17 /src/optionstr.c | |
parent | 0d2c4bf1714a6b286bd7a10061044414e0b17a15 (diff) | |
download | vim-git-a1cb1d1dce14dd005797590721f1bcd0e7c3b35f.tar.gz |
patch 8.1.2171: mouse support not always availablev8.1.2171
Problem: Mouse support not always available.
Solution: Enable mouse support also in tiny version. Do not define
FEAT_MOUSE_XTERM on MS-Windows (didn't really work).
Diffstat (limited to 'src/optionstr.c')
-rw-r--r-- | src/optionstr.c | 17 |
1 files changed, 4 insertions, 13 deletions
diff --git a/src/optionstr.c b/src/optionstr.c index a5b5b55a5..7b83aed25 100644 --- a/src/optionstr.c +++ b/src/optionstr.c @@ -47,7 +47,7 @@ static char *(p_toolbar_values[]) = {"text", "icons", "tooltips", "horiz", NULL} #if defined(FEAT_TOOLBAR) && defined(FEAT_GUI_GTK) static char *(p_tbis_values[]) = {"tiny", "small", "medium", "large", "huge", "giant", NULL}; #endif -#if defined(FEAT_MOUSE) && (defined(UNIX) || defined(VMS)) +#if defined(UNIX) || defined(VMS) static char *(p_ttym_values[]) = {"xterm", "xterm2", "dec", "netterm", "jsbterm", "pterm", "urxvt", "sgr", NULL}; #endif static char *(p_ve_values[]) = {"block", "insert", "all", "onemore", NULL}; @@ -110,7 +110,7 @@ didset_string_options(void) (void)opt_strings_flags(p_dy, p_dy_values, &dy_flags, TRUE); (void)opt_strings_flags(p_tc, p_tc_values, &tc_flags, FALSE); (void)opt_strings_flags(p_ve, p_ve_values, &ve_flags, TRUE); -#if defined(FEAT_MOUSE) && (defined(UNIX) || defined(VMS)) +#if defined(UNIX) || defined(VMS) (void)opt_strings_flags(p_ttym, p_ttym_values, &ttym_flags, FALSE); #endif #if defined(FEAT_TOOLBAR) && !defined(FEAT_GUI_MSWIN) @@ -1588,7 +1588,7 @@ did_set_string_option( } #endif -#if defined(FEAT_MOUSE_TTY) && (defined(UNIX) || defined(VMS)) +#if defined(UNIX) || defined(VMS) // 'ttymouse' else if (varp == &p_ttym) { @@ -2254,12 +2254,7 @@ did_set_string_option( #endif else if (varp == &p_mouse) // 'mouse' { -#ifdef FEAT_MOUSE p = (char_u *)MOUSE_ALL; -#else - if (*p_mouse != NUL) - errmsg = N_("E538: No mouse support"); -#endif } #if defined(FEAT_GUI) else if (varp == &p_go) // 'guioptions' @@ -2389,20 +2384,16 @@ did_set_string_option( #endif } -#ifdef FEAT_MOUSE if (varp == &p_mouse) { -# ifdef FEAT_MOUSE_TTY if (*p_mouse == NUL) mch_setmouse(FALSE); // switch mouse off else -# endif setmouse(); // in case 'mouse' changed } -#endif if (curwin->w_curswant != MAXCOL - && (get_option_flags(opt_idx) & (P_CURSWANT | P_RALL)) != 0) + && (get_option_flags(opt_idx) & (P_CURSWANT | P_RALL)) != 0) curwin->w_set_curswant = TRUE; #ifdef FEAT_GUI |