Blob Blame History Raw
To: vim-dev@vim.org
Subject: patch 7.1.078
Fcc: outbox
From: Bram Moolenaar <Bram@moolenaar.net>
Mime-Version: 1.0
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 8bit
------------

Patch 7.1.078
Problem:    Dropping a file name on gvim that contains a CSI byte doesn't work
	    when editing the command line.
Solution:   Escape the CSI byte when inserting in the input buffer. (Yukihiro
	    Nakadaira)
Files:	    src/gui.c, src/ui.c


*** ../vim-7.1.077/src/gui.c	Thu May 10 19:19:15 2007
--- src/gui.c	Tue Aug 14 12:41:43 2007
***************
*** 5117,5123 ****
  		p = vim_strsave_escaped(fnames[i], (char_u *)"\\ \t\"|");
  # endif
  		if (p != NULL)
! 		    add_to_input_buf(p, (int)STRLEN(p));
  		vim_free(p);
  		vim_free(fnames[i]);
  	    }
--- 5117,5123 ----
  		p = vim_strsave_escaped(fnames[i], (char_u *)"\\ \t\"|");
  # endif
  		if (p != NULL)
! 		    add_to_input_buf_csi(p, (int)STRLEN(p));
  		vim_free(p);
  		vim_free(fnames[i]);
  	    }
*** ../vim-7.1.077/src/ui.c	Thu May 10 21:14:11 2007
--- src/ui.c	Tue Aug 14 12:41:42 2007
***************
*** 1603,1610 ****
  #if defined(FEAT_GUI) || defined(FEAT_MOUSE_GPM) \
  	|| defined(FEAT_XCLIPBOARD) || defined(VMS) \
  	|| defined(FEAT_SNIFF) || defined(FEAT_CLIENTSERVER) \
- 	|| (defined(FEAT_GUI) && (!defined(USE_ON_FLY_SCROLL) \
- 		|| defined(FEAT_MENU))) \
  	|| defined(PROTO)
  /*
   * Add the given bytes to the input buffer
--- 1603,1608 ----
***************
*** 1630,1636 ****
  }
  #endif
  
! #if (defined(FEAT_XIM) && defined(FEAT_GUI_GTK)) \
  	|| (defined(FEAT_MBYTE) && defined(FEAT_MBYTE_IME)) \
  	|| (defined(FEAT_GUI) && (!defined(USE_ON_FLY_SCROLL) \
  		|| defined(FEAT_MENU))) \
--- 1628,1636 ----
  }
  #endif
  
! #if ((defined(FEAT_XIM) || defined(FEAT_DND)) && defined(FEAT_GUI_GTK)) \
! 	|| defined(FEAT_GUI_MSWIN) \
! 	|| defined(FEAT_GUI_MAC) \
  	|| (defined(FEAT_MBYTE) && defined(FEAT_MBYTE_IME)) \
  	|| (defined(FEAT_GUI) && (!defined(USE_ON_FLY_SCROLL) \
  		|| defined(FEAT_MENU))) \
*** ../vim-7.1.077/src/version.c	Tue Aug 14 23:06:51 2007
--- src/version.c	Wed Aug 15 20:07:06 2007
***************
*** 668,669 ****
--- 668,671 ----
  {   /* Add new patch number below this line */
+ /**/
+     78,
  /**/

-- 
hundred-and-one symptoms of being an internet addict:
164. You got out to buy software, instead of going out for a beer.

 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net   \\\
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\        download, build and distribute -- http://www.A-A-P.org        ///
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///