summaryrefslogtreecommitdiffstats
path: root/src/gui_mac.c
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2018-12-11 20:39:19 +0100
committerBram Moolenaar <Bram@vim.org>2018-12-11 20:39:19 +0100
commit295471920def98ce84bc96e5d97c16d250c81621 (patch)
tree7490f90afb9d639216c80a4942629a19510654ab /src/gui_mac.c
parent30700cd5ffa258f1d684ab6b34bd03e970450dba (diff)
patch 8.1.0577: tabpage right-click menu never shows "Close tab"v8.1.0577
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.
Diffstat (limited to 'src/gui_mac.c')
-rw-r--r--src/gui_mac.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/gui_mac.c b/src/gui_mac.c
index 96f04c55a3..ec8ec3adf8 100644
--- a/src/gui_mac.c
+++ b/src/gui_mac.c
@@ -6705,8 +6705,7 @@ initialise_tabline(void)
// create tabline popup menu required by vim docs (see :he tabline-menu)
CreateNewMenu(kTabContextMenuId, 0, &contextMenu);
- if (first_tabpage->tp_next != NULL)
- AppendMenuItemTextWithCFString(contextMenu, CFSTR("Close Tab"), 0,
+ AppendMenuItemTextWithCFString(contextMenu, CFSTR("Close Tab"), 0,
TABLINE_MENU_CLOSE, NULL);
AppendMenuItemTextWithCFString(contextMenu, CFSTR("New Tab"), 0,
TABLINE_MENU_NEW, NULL);