Mercurial > vim
comparison runtime/ftplugin.vim @ 36:125e80798a85 v7.0021
updated for version 7.0021
author | vimboss |
---|---|
date | Thu, 09 Dec 2004 21:34:53 +0000 |
parents | 3fc0f57ecb91 |
children | 9281a51ca7a2 |
comparison
equal
deleted
inserted
replaced
35:8f3a526c2fe1 | 36:125e80798a85 |
---|---|
1 " Vim support file to switch on loading plugins for file types | 1 " Vim support file to switch on loading plugins for file types |
2 " | 2 " |
3 " Maintainer: Bram Moolenaar <Bram@vim.org> | 3 " Maintainer: Bram Moolenaar <Bram@vim.org> |
4 " Last change: 2003 May 10 | 4 " Last change: 2004 Nov 22 |
5 | 5 |
6 if exists("did_load_ftplugin") | 6 if exists("did_load_ftplugin") |
7 finish | 7 finish |
8 endif | 8 endif |
9 let did_load_ftplugin = 1 | 9 let did_load_ftplugin = 1 |
12 au FileType * call s:LoadFTPlugin() | 12 au FileType * call s:LoadFTPlugin() |
13 func! s:LoadFTPlugin() | 13 func! s:LoadFTPlugin() |
14 if expand("<amatch>") != "" | 14 if expand("<amatch>") != "" |
15 if exists("b:undo_ftplugin") | 15 if exists("b:undo_ftplugin") |
16 exe b:undo_ftplugin | 16 exe b:undo_ftplugin |
17 unlet b:undo_ftplugin b:did_ftplugin | 17 unlet! b:undo_ftplugin b:did_ftplugin |
18 endif | 18 endif |
19 if &cpo =~# "S" && exists("b:did_ftplugin") | 19 if &cpo =~# "S" && exists("b:did_ftplugin") |
20 " In compatible mode options are reset to the global values, need to | 20 " In compatible mode options are reset to the global values, need to |
21 " set the local values also when a plugin was already used. | 21 " set the local values also when a plugin was already used. |
22 unlet b:did_ftplugin | 22 unlet b:did_ftplugin |