window local variables instead of buffer local
This commit is contained in:
parent
ad12c4f0a5
commit
6237b231bb
|
@ -315,15 +315,15 @@ nnoremap <space>ci :ColorVInsert<CR>
|
|||
nnoremap <space>cp :ColorVPicker<CR>
|
||||
|
||||
function! ToggleColorPreview() abort
|
||||
if !exists('b:colorv_is_previewing')
|
||||
let b:colorv_is_previewing = 0
|
||||
if !exists('w:colorv_is_previewing')
|
||||
let w:colorv_is_previewing = 0
|
||||
endif
|
||||
if b:colorv_is_previewing == 0
|
||||
if w:colorv_is_previewing == 0
|
||||
execute 'ColorVPreview'
|
||||
let b:colorv_is_previewing = 1
|
||||
let w:colorv_is_previewing = 1
|
||||
else
|
||||
execute 'ColorVClear'
|
||||
let b:colorv_is_previewing = 0
|
||||
let w:colorv_is_previewing = 0
|
||||
endif
|
||||
endfunction
|
||||
"}}}
|
||||
|
|
Loading…
Reference in New Issue