Use new access functions for buffer-local variables

Ref #256
This commit is contained in:
EinfachToll
2017-01-13 16:33:41 +01:00
parent ce5c822072
commit fea76ace23
3 changed files with 39 additions and 32 deletions

View File

@ -66,11 +66,11 @@ function! s:setup_new_wiki_buffer() "{{{
" to force a rescan of the filesystem which may have changed
" and update VimwikiLinks syntax group that depends on it;
" b:vimwiki_fs_rescan indicates that setup_filetype() has not been run
if exists('b:vimwiki_fs_rescan') && vimwiki#vars#get_wikilocal('maxhi')
" 'fs_rescan' indicates that setup_filetype() has not been run
if vimwiki#vars#get_bufferlocal('fs_rescan') == 1 && vimwiki#vars#get_wikilocal('maxhi')
set syntax=vimwiki
endif
let b:vimwiki_fs_rescan = 1
call vimwiki#vars#set_bufferlocal('fs_rescan', 1)
endfunction "}}}
@ -90,11 +90,11 @@ function! s:setup_buffer_enter() "{{{
elseif &syntax ==? 'vimwiki'
" to force a rescan of the filesystem which may have changed
" and update VimwikiLinks syntax group that depends on it;
" b:vimwiki_fs_rescan indicates that setup_filetype() has not been run
if exists("b:vimwiki_fs_rescan") && vimwiki#vars#get_wikilocal('maxhi')
" 'fs_rescan' indicates that setup_filetype() has not been run
if vimwiki#vars#get_bufferlocal('fs_rescan') == 1 && vimwiki#vars#get_wikilocal('maxhi')
set syntax=vimwiki
endif
let b:vimwiki_fs_rescan = 1
call vimwiki#vars#set_bufferlocal('fs_rescan', 1)
endif
" The settings foldmethod, foldexpr and foldtext are local to window. Thus in