Bram Moolenaar | 071d427 | 2004-06-13 20:20:40 +0000 | [diff] [blame] | 1 | " Vim filetype plugin file |
| 2 | " Language: jsp |
Bram Moolenaar | 1588bc8 | 2022-03-08 21:35:07 +0000 | [diff] [blame] | 3 | " |
| 4 | " This runtime file is looking for a new maintainer. |
| 5 | " |
| 6 | " Former maintainer: Dan Sharp |
Bram Moolenaar | 5c73622 | 2010-01-06 20:54:52 +0100 | [diff] [blame] | 7 | " Last Changed: 20 Jan 2009 |
Bram Moolenaar | 071d427 | 2004-06-13 20:20:40 +0000 | [diff] [blame] | 8 | |
| 9 | if exists("b:did_ftplugin") | finish | endif |
| 10 | |
| 11 | " Make sure the continuation lines below do not cause problems in |
| 12 | " compatibility mode. |
| 13 | let s:save_cpo = &cpo |
| 14 | set cpo-=C |
| 15 | |
| 16 | " Define some defaults in case the included ftplugins don't set them. |
| 17 | let s:undo_ftplugin = "" |
| 18 | let s:browsefilter = "Java Files (*.java)\t*.java\n" . |
Bram Moolenaar | 8299df9 | 2004-07-10 09:47:34 +0000 | [diff] [blame] | 19 | \ "HTML Files (*.html, *.htm)\t*.html;*.htm\n" . |
Bram Moolenaar | 071d427 | 2004-06-13 20:20:40 +0000 | [diff] [blame] | 20 | \ "All Files (*.*)\t*.*\n" |
| 21 | let s:match_words = "" |
| 22 | |
| 23 | runtime! ftplugin/html.vim ftplugin/html_*.vim ftplugin/html/*.vim |
| 24 | unlet b:did_ftplugin |
| 25 | |
| 26 | " Override our defaults if these were set by an included ftplugin. |
| 27 | if exists("b:undo_ftplugin") |
| 28 | let s:undo_ftplugin = b:undo_ftplugin |
| 29 | unlet b:undo_ftplugin |
| 30 | endif |
| 31 | if exists("b:browsefilter") |
| 32 | let s:browsefilter = b:browsefilter |
| 33 | unlet b:browsefilter |
| 34 | endif |
| 35 | if exists("b:match_words") |
| 36 | let s:match_words = b:match_words |
| 37 | unlet b:match_words |
| 38 | endif |
| 39 | |
| 40 | runtime! ftplugin/java.vim ftplugin/java_*.vim ftplugin/java/*.vim |
| 41 | let b:did_ftplugin = 1 |
| 42 | |
| 43 | " Combine the new set of values with those previously included. |
| 44 | if exists("b:undo_ftplugin") |
| 45 | let s:undo_ftplugin = b:undo_ftplugin . " | " . s:undo_ftplugin |
| 46 | endif |
| 47 | if exists ("b:browsefilter") |
| 48 | let s:browsefilter = b:browsefilter . s:browsefilter |
| 49 | endif |
| 50 | if exists("b:match_words") |
Bram Moolenaar | 95b28ec | 2005-10-11 20:32:28 +0000 | [diff] [blame] | 51 | let s:match_words = b:match_words . ',' . s:match_words |
Bram Moolenaar | 071d427 | 2004-06-13 20:20:40 +0000 | [diff] [blame] | 52 | endif |
| 53 | |
| 54 | " Load the combined list of match_words for matchit.vim |
| 55 | if exists("loaded_matchit") |
| 56 | let b:match_words = s:match_words |
| 57 | endif |
| 58 | |
| 59 | " Change the :browse e filter to primarily show JSP-related files. |
| 60 | if has("gui_win32") |
| 61 | let b:browsefilter="JSP Files (*.jsp)\t*.jsp\n" . s:browsefilter |
| 62 | endif |
| 63 | |
| 64 | " Undo the stuff we changed. |
| 65 | let b:undo_ftplugin = "unlet! b:browsefilter b:match_words | " . s:undo_ftplugin |
| 66 | |
| 67 | " Restore the saved compatibility options. |
| 68 | let &cpo = s:save_cpo |
Bram Moolenaar | 84f7235 | 2012-03-11 15:57:40 +0100 | [diff] [blame] | 69 | unlet s:save_cpo |