diff src/netbeans.c @ 6677:77172f5bac73 v7.4.663

updated for version 7.4.663 Problem: When using netbeans a buffer is not found in another tab. Solution: When 'switchbuf' is set to "usetab" then switch to another tab when possible. (Xavier de Gaye)
author Bram Moolenaar <bram@vim.org>
date Sat, 14 Mar 2015 15:35:52 +0100
parents f8f2a61e538d
children 97cc4ee3e095
line wrap: on
line diff
--- a/src/netbeans.c
+++ b/src/netbeans.c
@@ -2691,8 +2691,15 @@ nb_do_cmd(
     static void
 nb_set_curbuf(buf_T *buf)
 {
-    if (curbuf != buf && buf_jump_open_win(buf) == NULL)
+    if (curbuf != buf) {
+	if (buf_jump_open_win(buf) != NULL)
+	    return;
+# ifdef FEAT_WINDOWS
+	if ((swb_flags & SWB_USETAB) && buf_jump_open_tab(buf) != NULL)
+	    return;
+# endif
 	set_curbuf(buf, DOBUF_GOTO);
+    }
 }
 
 /*