patch 7.4.1611
Problem: The versplit feature makes the code uneccessary complicated.
Solution: Remove FEAT_VERTSPLIT, always support vertical splits when
FEAT_WINDOWS is defined.
diff --git a/src/ui.c b/src/ui.c
index a7c9064..f686138 100644
--- a/src/ui.c
+++ b/src/ui.c
@@ -2583,7 +2583,7 @@
int which_button) /* MOUSE_LEFT, MOUSE_RIGHT, MOUSE_MIDDLE */
{
static int on_status_line = 0; /* #lines below bottom of window */
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
static int on_sep_line = 0; /* on separator right of window */
#endif
static int prev_row = -1;
@@ -2623,7 +2623,7 @@
* line, stop Visual mode */
if (on_status_line)
return IN_STATUS_LINE;
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
if (on_sep_line)
return IN_SEP_LINE;
#endif
@@ -2681,7 +2681,7 @@
}
else
on_status_line = 0;
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
if (col >= wp->w_width) /* In separator line */
{
on_sep_line = col - wp->w_width + 1;
@@ -2706,7 +2706,7 @@
if (VIsual_active
&& (wp->w_buffer != curwin->w_buffer
|| (!on_status_line
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
&& !on_sep_line
#endif
#ifdef FEAT_FOLDING
@@ -2730,9 +2730,7 @@
{
/* A click outside the command-line window: Use modeless
* selection if possible. Allow dragging the status lines. */
-# ifdef FEAT_VERTSPLIT
on_sep_line = 0;
-# endif
# ifdef FEAT_CLIPBOARD
if (on_status_line)
return IN_STATUS_LINE;
@@ -2764,7 +2762,7 @@
else
return IN_STATUS_LINE | CURSOR_MOVED;
}
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
if (on_sep_line) /* In (or below) status line */
{
/* Don't use start_arrow() if we're in the same window */
@@ -2798,7 +2796,7 @@
#endif
return IN_STATUS_LINE; /* Cursor didn't move */
}
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
else if (on_sep_line && which_button == MOUSE_LEFT)
{
if (dragwin != NULL)
@@ -2828,7 +2826,7 @@
#endif
row -= W_WINROW(curwin);
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
col -= W_WINCOL(curwin);
#endif
@@ -3089,7 +3087,6 @@
{
if (fp->fr_layout == FR_LEAF)
break;
-#ifdef FEAT_VERTSPLIT
if (fp->fr_layout == FR_ROW)
{
for (fp = fp->fr_child; fp->fr_next != NULL; fp = fp->fr_next)
@@ -3099,7 +3096,6 @@
*colp -= fp->fr_width;
}
}
-#endif
else /* fr_layout == FR_COL */
{
for (fp = fp->fr_child; fp->fr_next != NULL; fp = fp->fr_next)
@@ -3141,7 +3137,7 @@
*/
if (row >= wp->w_height) /* In (or below) status line */
return IN_STATUS_LINE;
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
if (col >= wp->w_width) /* In vertical separator line */
return IN_SEP_LINE;
#endif