diff options
author | Bram Moolenaar <Bram@vim.org> | 2015-02-27 15:03:58 +0100 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2015-02-27 15:03:58 +0100 |
commit | dfd7691bb85b345bd86cf30945a66acf7c782920 (patch) | |
tree | 2f1061e419b9b4f36ca957bed9284c3700e01b1a /src/normal.c | |
parent | c3bbad085c3ec304b111dc95aed97fea4c38a177 (diff) | |
download | vim-git-dfd7691bb85b345bd86cf30945a66acf7c782920.tar.gz |
updated for version 7.4.641v7.4.641
Problem: The tabline menu was using ":999tabnew" which is now invalid.
Solution: Use ":$tabnew" instead. (Florian Degner)
Diffstat (limited to 'src/normal.c')
-rw-r--r-- | src/normal.c | 22 |
1 files changed, 16 insertions, 6 deletions
diff --git a/src/normal.c b/src/normal.c index 86d4504a9..987705d4c 100644 --- a/src/normal.c +++ b/src/normal.c @@ -5302,15 +5302,25 @@ handle_tabmenu() break; case TABLINE_MENU_NEW: - vim_snprintf((char *)IObuff, IOSIZE, "%dtabnew", - current_tab > 0 ? current_tab - 1 : 999); - do_cmdline_cmd(IObuff); + if (current_tab == 0) + do_cmdline_cmd((char_u *)"$tabnew"); + else + { + vim_snprintf((char *)IObuff, IOSIZE, "%dtabnew", + current_tab - 1); + do_cmdline_cmd(IObuff); + } break; case TABLINE_MENU_OPEN: - vim_snprintf((char *)IObuff, IOSIZE, "browse %dtabnew", - current_tab > 0 ? current_tab - 1 : 999); - do_cmdline_cmd(IObuff); + if (current_tab == 0) + do_cmdline_cmd((char_u *)"browse $tabnew"); + else + { + vim_snprintf((char *)IObuff, IOSIZE, "browse %dtabnew", + current_tab - 1); + do_cmdline_cmd(IObuff); + } break; } } |