Permalink
Browse files

<count>gc operator maps: use v:count instead of v:count1

  • Loading branch information...
1 parent d2bcf56 commit 0304190f4e01167bd39333c9f2429951df4010e9 @tomtom committed Nov 27, 2012
Showing with 3 additions and 3 deletions.
  1. +3 −3 plugin/tcomment.vim
View
@@ -2,8 +2,8 @@
" @Author: Tom Link (micathom AT gmail com)
" @License: GPL (see http://www.gnu.org/licenses/gpl.txt)
" @Created: 27-Dez-2004.
-" @Last Change: 2012-09-22.
-" @Revision: 760
+" @Last Change: 2012-11-26.
+" @Revision: 761
" GetLatestVimScripts: 1173 1 tcomment.vim
if &cp || exists('loaded_tcomment')
@@ -140,7 +140,7 @@ if (g:tcommentMapLeader2 != '')
exec 'noremap '. g:tcommentMapLeader2 .'s :TCommentAs <c-r>=&ft<cr>_'
endif
if (g:tcommentMapLeaderOp1 != '')
- exec 'nnoremap <silent> '. g:tcommentMapLeaderOp1 .' :<c-u>if v:count1 > 1 \| call tcomment#SetOption("count", v:count1) \| endif \| let w:tcommentPos = getpos(".") \| set opfunc=tcomment#Operator<cr>g@'
+ exec 'nnoremap <silent> '. g:tcommentMapLeaderOp1 .' :<c-u>if v:count > 0 \| call tcomment#SetOption("count", v:count) \| endif \| let w:tcommentPos = getpos(".") \| set opfunc=tcomment#Operator<cr>g@'
for s:i in range(1, 9)
exec 'nnoremap <silent> '. g:tcommentMapLeaderOp1 . s:i .'c :let w:tcommentPos = getpos(".") \| call tcomment#SetOption("count", '. s:i .') \| set opfunc=tcomment#Operator<cr>g@'
endfor

0 comments on commit 0304190

Please sign in to comment.