changeset 7090:052043fc57ab v7.4.857

commit https://github.com/vim/vim/commit/4a4b821085847651b71d8ad9fab9f180635cb453 Author: Bram Moolenaar <Bram@vim.org> Date: Tue Sep 8 17:50:41 2015 +0200 patch 7.4.857 Problem: Dragging the current tab with the mouse doesn't work properly. Solution: Take the current tabpage index into account. (Hirohito Higashi)
author Christian Brabandt <cb@256bit.org>
date Tue, 08 Sep 2015 18:00:04 +0200
parents 28eae82172f4
children 0f1600f46238
files src/normal.c src/version.c
diffstat 2 files changed, 4 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/src/normal.c
+++ b/src/normal.c
@@ -2561,7 +2561,8 @@ do_mouse(oap, c, dir, count, fixindent)
 	    if (in_tab_line)
 	    {
 		c1 = TabPageIdxs[mouse_col];
-		tabpage_move(c1 <= 0 ? 9999 : c1 - 1);
+		tabpage_move(c1 <= 0 ? 9999 : c1 < tabpage_index(curtab)
+								? c1 - 1 : c1);
 	    }
 	    return FALSE;
 	}
--- a/src/version.c
+++ b/src/version.c
@@ -742,6 +742,8 @@ static char *(features[]) =
 static int included_patches[] =
 {   /* Add new patch number below this line */
 /**/
+    857,
+/**/
     856,
 /**/
     855,