Commits

Takeshi NISHIDA committed 6db3cac

minor fix

Comments (0)

Files changed (4)

 
 "
 function fuf#formatPrompt(prompt, partialMatching, otherString)
-  let indicator = (a:partialMatching ? '!' : '') . a:otherString
+  let indicator = escape((a:partialMatching ? '!' : '') . a:otherString, '\')
   return substitute(a:prompt, '[]', indicator, 'g')
 endfunction
 
   function listener.onComplete(modeName, method)
     let bufName = '[fuf-info-' . a:modeName . ']'
     let lines = l9#readFile(l9#concatPaths([g:fuf_dataDir, a:modeName, 'items']))
-    call l9#tempbuffer#open(bufName, 'vim', lines, 0, 0, 0, 1,
-          \                 s:createDataBufferListener(a:modeName))
+    call l9#tempbuffer#openWritable(bufName, 'vim', lines, 0, 0, 0,
+          \                         s:createDataBufferListener(a:modeName))
   endfunction
 
   return listener
   "         if 'autochdir' was set on.
   lcd .
   let cwd = getcwd()
-  call l9#tempbuffer#open(s:FUF_BUF_NAME, 'fuf', [], 1, 0, 1, 1, {})
+  call l9#tempbuffer#openScratch(s:FUF_BUF_NAME, 'fuf', [], 1, 0, 1)
   resize 1 " for issue #21 
   " lcd ... : countermeasure against auto-cd script
   lcd `=cwd`
-  setlocal buftype=nofile
   setlocal nocursorline   " for highlighting
   setlocal nocursorcolumn " for highlighting
   setlocal omnifunc=fuf#onComplete
 
 必要なもの: ~
 
-- L9 library ( http://bitbucket.org/ns9tks/vim-l9/ )
+- L9 library (vimscript #3252)
 
 
 ==============================================================================
 
 Requirements: ~
 
-- L9 library ( http://bitbucket.org/ns9tks/vim-l9/ )
+- L9 library (vimscript #3252)
 
 
 ==============================================================================
 ==============================================================================
 CHANGELOG                                                      *fuf-changelog*
 
-4.0: [TODO]
+4.0:
+  - From this version, L9 library (vimscript #3252) is required.
   - Added All-File mode for users wanting something like TextMate's command-t.
   - Added Around-MRU-File mode. (Too slow. There is room for improvement.)
   - Added new feature which deletes selected buffer with FuzzyFinder and
 "=============================================================================
 " LOAD GUARD {{{1
 
-if !l9#guardScriptLoading(expand('<sfile>:p'), 702, 100)
+try
+  if !l9#guardScriptLoading(expand('<sfile>:p'), 702, 100)
+    finish
+  endif
+catch /E117/
+  echoerr '***** L9 library must be installed! *****'
   finish
-endif
+endtry
 
 " }}}1
 "=============================================================================