Remove vim tab movement stuff. Was messing shit up
This commit is contained in:
parent
65a82734f1
commit
17b7c8406d
48
.vimrc
48
.vimrc
|
@ -311,51 +311,3 @@ function! RunTests(filename)
|
|||
end
|
||||
endfunction
|
||||
|
||||
" From http://vim.wikia.com/wiki/Move_current_window_between_tabs
|
||||
" Moves a window from one tab to another.
|
||||
function! MoveToPrevTab()
|
||||
"there is only one window
|
||||
if tabpagenr('$') == 1 && winnr('$') == 1
|
||||
return
|
||||
endif
|
||||
"preparing new window
|
||||
let l:tab_nr = tabpagenr('$')
|
||||
let l:cur_buf = bufnr('%')
|
||||
if tabpagenr() != 1
|
||||
close!
|
||||
if l:tab_nr == tabpagenr('$')
|
||||
tabprev
|
||||
endif
|
||||
sp
|
||||
else
|
||||
close!
|
||||
exe "0tabnew"
|
||||
endif
|
||||
"opening current buffer in new window
|
||||
exe "b".l:cur_buf
|
||||
endfunction
|
||||
|
||||
function! MoveToNextTab()
|
||||
"there is only one window
|
||||
if tabpagenr('$') == 1 && winnr('$') == 1
|
||||
return
|
||||
endif
|
||||
"preparing new window
|
||||
let l:tab_nr = tabpagenr('$')
|
||||
let l:cur_buf = bufnr('%')
|
||||
if tabpagenr() < tab_nr
|
||||
close!
|
||||
if l:tab_nr == tabpagenr('$')
|
||||
tabnext
|
||||
endif
|
||||
sp
|
||||
else
|
||||
close!
|
||||
tabnew
|
||||
endif
|
||||
"opening current buffer in new window
|
||||
exe "b".l:cur_buf
|
||||
endfunction
|
||||
map <C-m> :call MoveToNextTab()<CR><C-w>H
|
||||
map <C-n> :call MoveToPrevTab()<CR><C-w>H
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user