]> granicus.if.org Git - vim/commitdiff
patch 8.0.1520: cursor in wrong line when using a WinBar in Terminal window v8.0.1520
authorBram Moolenaar <Bram@vim.org>
Tue, 13 Feb 2018 20:19:21 +0000 (21:19 +0100)
committerBram Moolenaar <Bram@vim.org>
Tue, 13 Feb 2018 20:19:21 +0000 (21:19 +0100)
Problem:    Cursor is in the wrong line when using a WinBar in a Terminal
            window.
Solution:   Adjust the row number. (Christian Brabandt, closes #2362)

src/screen.c
src/terminal.c
src/version.c

index ce9b6e98e8c3f28120f69fa582409b87b813d10f..97f69882bf3ac57dced627cc56f681c9a812f614 100644 (file)
@@ -1176,6 +1176,11 @@ win_update(win_T *wp)
      */
     if (term_update_window(wp) == OK)
     {
+# ifdef FEAT_MENU
+       /* Draw the window toolbar, if there is one. */
+       if (winbar_height(wp) > 0)
+           redraw_win_toolbar(wp);
+# endif
        wp->w_redr_type = 0;
        return;
     }
index eca9f1bd8632cf834c3f42da5ea5db839a70ba0d..039c8b26b0e896f78dc53b921d57303d3f9df7ac 100644 (file)
@@ -2398,8 +2398,8 @@ term_update_window(win_T *wp)
        else
            pos.col = 0;
 
-       screen_line(wp->w_winrow + pos.row, wp->w_wincol,
-                                                 pos.col, wp->w_width, FALSE);
+       screen_line(wp->w_winrow + pos.row + winbar_height(wp),
+                                   wp->w_wincol, pos.col, wp->w_width, FALSE);
     }
     term->tl_dirty_row_start = MAX_ROW;
     term->tl_dirty_row_end = 0;
index 24eef2e8a155053f9cf9225f071e2099a974ac3c..c7240f1a67c99b26ebf482b79ad6db481fc2560c 100644 (file)
@@ -771,6 +771,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    1520,
 /**/
     1519,
 /**/