Преглед на файлове

use double-click to select an entry

Previously a single-click was used. But this introduced a bug that
was suprisingly hard to prevent because of the 'line skipping feature'.

If one changed to another tab and then used a mouse click on the tabpage
to jump back to the tab containing the startify buffer, the click would
have delegated into the buffer and select the next entry automatically.

Just using a double-click prevents this without adding complex code.
Marco Hinz преди 13 години
родител
ревизия
aab37d4ccd
променени са 1 файла, в които са добавени 1 реда и са изтрити 1 реда
  1. 1 1
      plugin/startify.vim

+ 1 - 1
plugin/startify.vim

@@ -91,7 +91,7 @@ function! s:insane_in_the_membrane() abort
   nnoremap <buffer> q :quit<cr>
   nnoremap <buffer><silent> e :enew<cr>
   nnoremap <buffer><silent> <cr> :normal <c-r><c-w><cr>
-  nnoremap <buffer><silent> <LeftRelease> :execute 'normal '. matchstr(getline('.'), '\w\+')<cr>
+  nnoremap <buffer><silent> <2-LeftMouse> :execute 'normal '. matchstr(getline('.'), '\w\+')<cr>
 
   if exists('g:startify_empty_buffer_key')
     execute 'nnoremap <buffer><silent> '. g:startify_empty_buffer_key .' :enew<cr>'