Merge pull request #544 from wincent/fix-autocmd
Use <nomodeline> when firing user autocmds
This commit is contained in:
commit
29ad00ec0f
@ -374,7 +374,7 @@ class SnippetManager(object):
|
|||||||
'autocmd CmdwinLeave * call UltiSnips#LeavingBuffer()')
|
'autocmd CmdwinLeave * call UltiSnips#LeavingBuffer()')
|
||||||
_vim.command('augroup END')
|
_vim.command('augroup END')
|
||||||
|
|
||||||
_vim.command('silent doautocmd User UltiSnipsEnterFirstSnippet')
|
_vim.command('silent doautocmd <nomodeline> User UltiSnipsEnterFirstSnippet')
|
||||||
self._inner_state_up = True
|
self._inner_state_up = True
|
||||||
|
|
||||||
def _teardown_inner_state(self):
|
def _teardown_inner_state(self):
|
||||||
@ -382,7 +382,7 @@ class SnippetManager(object):
|
|||||||
if not self._inner_state_up:
|
if not self._inner_state_up:
|
||||||
return
|
return
|
||||||
try:
|
try:
|
||||||
_vim.command('silent doautocmd User UltiSnipsExitLastSnippet')
|
_vim.command('silent doautocmd <nomodeline> User UltiSnipsExitLastSnippet')
|
||||||
if self.expand_trigger != self.forward_trigger:
|
if self.expand_trigger != self.forward_trigger:
|
||||||
_vim.command('iunmap <buffer> %s' % self.forward_trigger)
|
_vim.command('iunmap <buffer> %s' % self.forward_trigger)
|
||||||
_vim.command('sunmap <buffer> %s' % self.forward_trigger)
|
_vim.command('sunmap <buffer> %s' % self.forward_trigger)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user