diff src/edit.c @ 692:a28f83d37113

updated for version 7.0208
author vimboss
date Mon, 27 Feb 2006 00:08:02 +0000
parents a39b8af64334
children 07d199fe02ed
line wrap: on
line diff
--- a/src/edit.c
+++ b/src/edit.c
@@ -202,6 +202,9 @@ static int  ins_bs __ARGS((int c, int mo
 static void ins_mouse __ARGS((int c));
 static void ins_mousescroll __ARGS((int up));
 #endif
+#if defined(FEAT_GUI_TABLINE) || defined(PROTO)
+static void ins_tabline __ARGS((int c));
+#endif
 static void ins_left __ARGS((void));
 static void ins_home __ARGS((int c));
 static void ins_end __ARGS((int c));
@@ -1044,6 +1047,12 @@ doESCkey:
 	    ins_mousescroll(TRUE);
 	    break;
 #endif
+#ifdef FEAT_GUI_TABLINE
+	case K_TABLINE:
+	case K_TABMENU:
+	    ins_tabline(c);
+	    break;
+#endif
 
 	case K_IGNORE:	/* Something mapped to nothing */
 	    break;
@@ -3515,7 +3524,7 @@ ins_compl_get_exp(ini)
 		    found_new_match = searchit(NULL, ins_buf, pos,
 							      compl_direction,
 				 compl_pattern, 1L, SEARCH_KEEP + SEARCH_NFMSG,
-								     RE_LAST);
+							RE_LAST, (linenr_T)0);
 		if (!compl_started)
 		{
 		    /* set "compl_started" even on fail */
@@ -7978,7 +7987,31 @@ ins_mousescroll(up)
 }
 #endif
 
-#ifdef FEAT_GUI
+#if defined(FEAT_GUI_TABLINE) || defined(PROTO)
+    void
+ins_tabline(c)
+    int		c;
+{
+    /* We will be leaving the current window, unless closing another tab. */
+    if (c != K_TABMENU || current_tabmenu != TABLINE_MENU_CLOSE
+		|| (current_tab != 0 && current_tab != tabpage_index(curtab)))
+    {
+	undisplay_dollar();
+	start_arrow(&curwin->w_cursor);
+# ifdef FEAT_CINDENT
+	can_cindent = TRUE;
+# endif
+    }
+
+    if (c == K_TABLINE)
+	goto_tabpage(current_tab);
+    else
+	handle_tabmenu();
+
+}
+#endif
+
+#if defined(FEAT_GUI) || defined(PROTO)
     void
 ins_scroll()
 {