aboutsummaryrefslogtreecommitdiff
path: root/plugin
diff options
context:
space:
mode:
authorThomas Buckley-Houston2017-06-25 14:29:47 +0000
committerThomas Buckley-Houston2017-06-25 14:31:46 +0000
commit70939c41f37173873096ec7cd5ad45e32f84b0cb (patch)
tree81526ab3243b9377cc77e863f0e85ce65406eb76 /plugin
parentd29f111ba8ebc1fdeafbe04ab01aab99c8e0e1ca (diff)
Actually compare `has('timers')` to something :/
This properly deals with versions of VIm that don't support timers. So that older versions of Vim still work but run into the bug where some panes get insertmode inappropriately set. Touches #4
Diffstat (limited to 'plugin')
-rw-r--r--plugin/novim_mode.vim12
1 files changed, 7 insertions, 5 deletions
diff --git a/plugin/novim_mode.vim b/plugin/novim_mode.vim
index 97d61c6..c30d5de 100644
--- a/plugin/novim_mode.vim
+++ b/plugin/novim_mode.vim
@@ -37,12 +37,14 @@ endfunction
call s:init_settings(s:settings)
-" Plugin entry point
-if has('timers')
- call g:novim_mode#StartNoVimMode()
-else
- echo 'Novim-mode will not work this version of Vim (no `timer` support).'
+if has('timers') == 0
+ echo "Novim-mode: Your Vim version (Vim <7.5 or Neovim <0.1.5) doesn't "
+ echo "support `timer()`, which causes a bug where Insert Mode is "
+ echo "innapropriately set for some panes."
endif
+" Plugin entry point
+call g:novim_mode#StartNoVimMode()
+
let &cpo = s:save_cpo
unlet s:save_cpo