mirror of
https://github.com/Raimondi/delimitMate.git
synced 2025-12-06 12:44:27 +08:00
Fix: automatic indent was broken when expanding <CR>.
This commit is contained in:
@@ -442,19 +442,18 @@ function! delimitMate#MapMsg(msg) "{{{
|
||||
endfunction "}}}
|
||||
|
||||
function! delimitMate#ExpandReturn() "{{{
|
||||
if delimitMate#WithinEmptyPair() &&
|
||||
\ b:delimitMate_expand_cr
|
||||
if delimitMate#WithinEmptyPair()
|
||||
" Expand:
|
||||
call delimitMate#FlushBuffer()
|
||||
return "\<Esc>a\<CR>x\<CR>\<Esc>k$\"_xa"
|
||||
"return "\<Esc>a\<CR>x\<CR>\<Esc>k$\"_xa"
|
||||
return "\<CR>\<UP>\<Esc>o"
|
||||
else
|
||||
return "\<CR>"
|
||||
endif
|
||||
endfunction "}}}
|
||||
|
||||
function! delimitMate#ExpandSpace() "{{{
|
||||
if delimitMate#WithinEmptyPair() &&
|
||||
\ b:delimitMate_expand_space
|
||||
if delimitMate#WithinEmptyPair()
|
||||
" Expand:
|
||||
call insert(b:delimitMate_buffer, 's')
|
||||
return delimitMate#WriteAfter(' ') . "\<Space>"
|
||||
|
||||
Reference in New Issue
Block a user