Mercurial > vim
diff src/gui_gtk_x11.c @ 15134:f2972ff144ab v8.1.0577
patch 8.1.0577: tabpage right-click menu never shows "Close tab"
commit https://github.com/vim/vim/commit/295471920def98ce84bc96e5d97c16d250c81621
Author: Bram Moolenaar <Bram@vim.org>
Date: Tue Dec 11 20:39:19 2018 +0100
patch 8.1.0577: tabpage right-click menu never shows "Close tab"
Problem: Tabpage right-click menu never shows "Close tab".
Solution: Always create the "Close tab" item but ignore the event if there
is only one tab.
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Tue, 11 Dec 2018 20:45:06 +0100 |
parents | 6e4e0d43b20b |
children | 55ccc2d353bd |
line wrap: on
line diff
--- a/src/gui_gtk_x11.c +++ b/src/gui_gtk_x11.c @@ -3337,9 +3337,7 @@ create_tabline_menu(void) GtkWidget *menu; menu = gtk_menu_new(); - if (first_tabpage->tp_next != NULL) - add_tabline_menu_item(menu, (char_u *)_("Close tab"), - TABLINE_MENU_CLOSE); + add_tabline_menu_item(menu, (char_u *)_("Close tab"), TABLINE_MENU_CLOSE); add_tabline_menu_item(menu, (char_u *)_("New tab"), TABLINE_MENU_NEW); add_tabline_menu_item(menu, (char_u *)_("Open Tab..."), TABLINE_MENU_OPEN);