mirror of
https://github.com/vim/vim.git
synced 2025-09-27 04:14:06 -04:00
patch 8.0.1570: can't use :popup for a menu in the terminal
Problem: Can't use :popup for a menu in the terminal. (Wei Zhang) Solution: Make :popup work in the terminal. Also fix that entries were included that don't work in the current state.
This commit is contained in:
@@ -204,7 +204,8 @@ static void ex_tearoff(exarg_T *eap);
|
||||
#else
|
||||
# define ex_tearoff ex_ni
|
||||
#endif
|
||||
#if (defined(FEAT_GUI_MSWIN) || defined(FEAT_GUI_GTK)) && defined(FEAT_MENU)
|
||||
#if (defined(FEAT_GUI_MSWIN) || defined(FEAT_GUI_GTK) \
|
||||
|| defined(FEAT_TERM_POPUP_MENU)) && defined(FEAT_MENU)
|
||||
static void ex_popup(exarg_T *eap);
|
||||
#else
|
||||
# define ex_popup ex_ni
|
||||
@@ -8741,11 +8742,21 @@ ex_tearoff(exarg_T *eap)
|
||||
}
|
||||
#endif
|
||||
|
||||
#if (defined(FEAT_GUI_MSWIN) || defined(FEAT_GUI_GTK)) && defined(FEAT_MENU)
|
||||
#if (defined(FEAT_GUI_MSWIN) || defined(FEAT_GUI_GTK) \
|
||||
|| defined(FEAT_TERM_POPUP_MENU)) && defined(FEAT_MENU)
|
||||
static void
|
||||
ex_popup(exarg_T *eap)
|
||||
{
|
||||
gui_make_popup(eap->arg, eap->forceit);
|
||||
# if defined(FEAT_GUI_MSWIN) || defined(FEAT_GUI_GTK)
|
||||
if (gui.in_use)
|
||||
gui_make_popup(eap->arg, eap->forceit);
|
||||
# ifdef FEAT_TERM_POPUP_MENU
|
||||
else
|
||||
# endif
|
||||
# endif
|
||||
# ifdef FEAT_TERM_POPUP_MENU
|
||||
pum_make_popup(eap->arg, eap->forceit);
|
||||
# endif
|
||||
}
|
||||
#endif
|
||||
|
||||
|
Reference in New Issue
Block a user