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

patch 8.1.1537: using "tab" for popup window can be confusing

Problem:    Using "tab" for popup window can be confusing.
Solution:   Use "tabpage". (Hirohito Higashi, closes #4532)
This commit is contained in:
Bram Moolenaar
2019-06-15 14:14:31 +02:00
parent 1755ec4278
commit fc06cbbf86
4 changed files with 30 additions and 18 deletions

View File

@@ -748,8 +748,8 @@ popup_create(typval_T *argvars, typval_T *rettv, create_type_T type)
// Avoid that 'buftype' is reset when this buffer is entered.
buf->b_p_initialized = TRUE;
if (dict_find(d, (char_u *)"tab", -1) != NULL)
nr = (int)dict_get_number(d, (char_u *)"tab");
if (dict_find(d, (char_u *)"tabpage", -1) != NULL)
nr = (int)dict_get_number(d, (char_u *)"tabpage");
else if (type == TYPE_NOTIFICATION)
nr = -1; // notifications are global by default
else
@@ -757,7 +757,7 @@ popup_create(typval_T *argvars, typval_T *rettv, create_type_T type)
if (nr == 0)
{
// popup on current tab
// popup on current tab page
wp->w_next = curtab->tp_first_popupwin;
curtab->tp_first_popupwin = wp;
}
@@ -1228,7 +1228,7 @@ not_in_popup_window()
/*
* Reset all the POPF_HANDLED flags in global popup windows and popup windows
* in the current tab.
* in the current tab page.
*/
void
popup_reset_handled()