diff options
author | Bram Moolenaar <Bram@vim.org> | 2010-07-11 17:23:02 +0200 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2010-07-11 17:23:02 +0200 |
commit | 3acfc30409eb8e3721d888f2e7111111057fe937 (patch) | |
tree | 22ca3ab3536417810973c22fd67caf32bf453945 /src/edit.c | |
parent | 9028b10dfe3a00e505bf1b720f515dab91913b5e (diff) | |
download | vim-3acfc30409eb8e3721d888f2e7111111057fe937.zip |
Improve Javascript indenting. Add "J" flag to 'cino'. (Hari Kumar G)
Diffstat (limited to 'src/edit.c')
-rw-r--r-- | src/edit.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/edit.c b/src/edit.c index 3ee76553c..2db06cf0c 100644 --- a/src/edit.c +++ b/src/edit.c @@ -7545,7 +7545,8 @@ in_cinkeys(keytyped, when, line_is_empty) if (try_match && keytyped == ':') { p = ml_get_curline(); - if (cin_iscase(p) || cin_isscopedecl(p) || cin_islabel(30)) + if (cin_iscase(p, FALSE) || cin_isscopedecl(p) + || cin_islabel(30)) return TRUE; /* Need to get the line again after cin_islabel(). */ p = ml_get_curline(); @@ -7554,7 +7555,7 @@ in_cinkeys(keytyped, when, line_is_empty) && p[curwin->w_cursor.col - 2] == ':') { p[curwin->w_cursor.col - 1] = ' '; - i = (cin_iscase(p) || cin_isscopedecl(p) + i = (cin_iscase(p, FALSE) || cin_isscopedecl(p) || cin_islabel(30)); p = ml_get_curline(); p[curwin->w_cursor.col - 1] = ':'; |