2020-12-07 16:36:17 +01:00
|
|
|
" Enable mouse by default, provide <Leader>om shortcut to toggle on/off
|
2015-03-02 17:58:40 +01:00
|
|
|
|
|
|
|
function! <SID>ToggleMouse()
|
|
|
|
if &g:mouse != ""
|
|
|
|
echo "Mouse disabled."
|
|
|
|
set mouse=
|
|
|
|
else
|
|
|
|
echo "Mouse enabled."
|
|
|
|
set mouse=a
|
|
|
|
endif
|
|
|
|
endfunction
|
|
|
|
|
|
|
|
set mouse=a
|
2020-12-07 16:36:17 +01:00
|
|
|
nnoremap <silent> <Leader>om :call <SID>ToggleMouse()<cr>
|