diff options
author | Bram Moolenaar <Bram@vim.org> | 2012-03-16 19:24:26 +0100 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2012-03-16 19:24:26 +0100 |
commit | 1ea69b7077fe26466210bd00bb20c35be84cca40 (patch) | |
tree | 1b112be14b7fde5bea6d0f287a8d736deb9cf819 /src/move.c | |
parent | 5ad15df9ce49f0b7adeac2c8387319d6f309bd5f (diff) |
updated for version 7.3.473v7.3.473
Problem: 'cursorbind' does not work correctly in combination with
'virtualedit' set to "all".
Solution: Copy coladd. (Gary Johnson)
Diffstat (limited to 'src/move.c')
-rw-r--r-- | src/move.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/move.c b/src/move.c index ccbb4addc4..fb033933ca 100644 --- a/src/move.c +++ b/src/move.c @@ -2843,7 +2843,10 @@ halfpage(flag, Prenum) do_check_cursorbind() { linenr_T line = curwin->w_cursor.lnum; - colnr_T col = curwin->w_cursor.col; + colnr_T col = curwin->w_cursor.col; +# ifdef FEAT_VIRTUALEDIT + colnr_T coladd = curwin->w_cursor.coladd; +# endif win_T *old_curwin = curwin; buf_T *old_curbuf = curbuf; int restart_edit_save; @@ -2875,6 +2878,9 @@ do_check_cursorbind() # endif curwin->w_cursor.lnum = line; curwin->w_cursor.col = col; +# ifdef FEAT_VIRTUALEDIT + curwin->w_cursor.coladd = coladd; +# endif /* Make sure the cursor is in a valid position. Temporarily set * "restart_edit" to allow the cursor to be beyond the EOL. */ |