Skip to content

Commit

Permalink
Fix overriding the default register in Lookup
Browse files Browse the repository at this point in the history
  • Loading branch information
Shahaf Arad committed Jul 10, 2015
1 parent 0d4ede9 commit 1b82176
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions plugin/online-thesaurus.vim
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ let s:path = shellescape(expand("<sfile>:p:h") . s:script_name)


function! s:Lookup(word)
let reg_save = @@
silent! let l:thesaurus_window = bufwinnr('^thesaurus$')

if l:thesaurus_window > -1
Expand All @@ -61,6 +62,7 @@ function! s:Lookup(word)
exec 'resize ' . (line('$') - 1)
setlocal nomodifiable filetype=thesaurus
nnoremap <silent> <buffer> q :q<CR>
let @@ = reg_save
endfunction

function! s:LookupVisual(mode)
Expand Down

0 comments on commit 1b82176

Please sign in to comment.