From 16929c8d5d09683774446dde6956366c291fab14 Mon Sep 17 00:00:00 2001 From: Junegunn Choi Date: Fri, 11 Apr 2014 21:12:31 +0900 Subject: [PATCH] Go back to the correct tab when disabling Goyo (#24) --- plugin/goyo.vim | 3 +++ 1 file changed, 3 insertions(+) diff --git a/plugin/goyo.vim b/plugin/goyo.vim index 5519dd5..311589e 100644 --- a/plugin/goyo.vim +++ b/plugin/goyo.vim @@ -115,6 +115,8 @@ function! s:tranquilize() endfunction function! s:goyo_on(width) + let s:orig_tab = tabpagenr() + " New tab tab split @@ -249,6 +251,7 @@ function! s:goyo_off() bd endif tabclose + execute 'normal! '.s:orig_tab.'gt' let wmh = remove(goyo_revert, 'winminheight') let wh = remove(goyo_revert, 'winheight')