Karsten Hopp 7eee43
To: vim_dev@googlegroups.com
Karsten Hopp 7eee43
Subject: Patch 7.4.807
Karsten Hopp 7eee43
Fcc: outbox
Karsten Hopp 7eee43
From: Bram Moolenaar <Bram@moolenaar.net>
Karsten Hopp 7eee43
Mime-Version: 1.0
Karsten Hopp 7eee43
Content-Type: text/plain; charset=UTF-8
Karsten Hopp 7eee43
Content-Transfer-Encoding: 8bit
Karsten Hopp 7eee43
------------
Karsten Hopp 7eee43
Karsten Hopp 7eee43
Patch 7.4.807 (after 7.4.798)
Karsten Hopp 7eee43
Problem:    After CTRL-V CTRL-A mode isn't updated. (Hirohito Higashi)
Karsten Hopp 7eee43
Solution:   Clear the command line or update the displayed command.
Karsten Hopp 7eee43
Files:      src/normal.c
Karsten Hopp 7eee43
Karsten Hopp 7eee43
Karsten Hopp 7eee43
*** ../vim-7.4.806/src/normal.c	2015-07-28 11:21:27.041407266 +0200
Karsten Hopp 7eee43
--- src/normal.c	2015-08-04 19:09:32.059034805 +0200
Karsten Hopp 7eee43
***************
Karsten Hopp 7eee43
*** 48,53 ****
Karsten Hopp 7eee43
--- 48,54 ----
Karsten Hopp 7eee43
  static void	clearop __ARGS((oparg_T *oap));
Karsten Hopp 7eee43
  static void	clearopbeep __ARGS((oparg_T *oap));
Karsten Hopp 7eee43
  static void	unshift_special __ARGS((cmdarg_T *cap));
Karsten Hopp 7eee43
+ static void	may_clear_cmdline __ARGS((void));
Karsten Hopp 7eee43
  #ifdef FEAT_CMDL_INFO
Karsten Hopp 7eee43
  static void	del_from_showcmd __ARGS((int));
Karsten Hopp 7eee43
  #endif
Karsten Hopp 7eee43
***************
Karsten Hopp 7eee43
*** 1752,1763 ****
Karsten Hopp 7eee43
  		setmouse();
Karsten Hopp 7eee43
  		mouse_dragging = 0;
Karsten Hopp 7eee43
  #endif
Karsten Hopp 7eee43
! 		if (mode_displayed)
Karsten Hopp 7eee43
! 		    clear_cmdline = TRUE;   /* unshow visual mode later */
Karsten Hopp 7eee43
! #ifdef FEAT_CMDL_INFO
Karsten Hopp 7eee43
! 		else
Karsten Hopp 7eee43
! 		    clear_showcmd();
Karsten Hopp 7eee43
! #endif
Karsten Hopp 7eee43
  		if ((oap->op_type == OP_YANK
Karsten Hopp 7eee43
  			    || oap->op_type == OP_COLON
Karsten Hopp 7eee43
  			    || oap->op_type == OP_FUNCTION
Karsten Hopp 7eee43
--- 1753,1759 ----
Karsten Hopp 7eee43
  		setmouse();
Karsten Hopp 7eee43
  		mouse_dragging = 0;
Karsten Hopp 7eee43
  #endif
Karsten Hopp 7eee43
! 		may_clear_cmdline();
Karsten Hopp 7eee43
  		if ((oap->op_type == OP_YANK
Karsten Hopp 7eee43
  			    || oap->op_type == OP_COLON
Karsten Hopp 7eee43
  			    || oap->op_type == OP_FUNCTION
Karsten Hopp 7eee43
***************
Karsten Hopp 7eee43
*** 3312,3324 ****
Karsten Hopp 7eee43
      if (!virtual_active())
Karsten Hopp 7eee43
  	curwin->w_cursor.coladd = 0;
Karsten Hopp 7eee43
  #endif
Karsten Hopp 7eee43
! 
Karsten Hopp 7eee43
!     if (mode_displayed)
Karsten Hopp 7eee43
! 	clear_cmdline = TRUE;		/* unshow visual mode later */
Karsten Hopp 7eee43
! #ifdef FEAT_CMDL_INFO
Karsten Hopp 7eee43
!     else
Karsten Hopp 7eee43
! 	clear_showcmd();
Karsten Hopp 7eee43
! #endif
Karsten Hopp 7eee43
  
Karsten Hopp 7eee43
      adjust_cursor_eol();
Karsten Hopp 7eee43
  }
Karsten Hopp 7eee43
--- 3308,3314 ----
Karsten Hopp 7eee43
      if (!virtual_active())
Karsten Hopp 7eee43
  	curwin->w_cursor.coladd = 0;
Karsten Hopp 7eee43
  #endif
Karsten Hopp 7eee43
!     may_clear_cmdline();
Karsten Hopp 7eee43
  
Karsten Hopp 7eee43
      adjust_cursor_eol();
Karsten Hopp 7eee43
  }
Karsten Hopp 7eee43
***************
Karsten Hopp 7eee43
*** 3763,3768 ****
Karsten Hopp 7eee43
--- 3753,3773 ----
Karsten Hopp 7eee43
      cap->cmdchar = simplify_key(cap->cmdchar, &mod_mask);
Karsten Hopp 7eee43
  }
Karsten Hopp 7eee43
  
Karsten Hopp 7eee43
+ /*
Karsten Hopp 7eee43
+  * If the mode is currently displayed clear the command line or update the
Karsten Hopp 7eee43
+  * command displayed.
Karsten Hopp 7eee43
+  */
Karsten Hopp 7eee43
+     static void
Karsten Hopp 7eee43
+ may_clear_cmdline()
Karsten Hopp 7eee43
+ {
Karsten Hopp 7eee43
+     if (mode_displayed)
Karsten Hopp 7eee43
+ 	clear_cmdline = TRUE;   /* unshow visual mode later */
Karsten Hopp 7eee43
+ #ifdef FEAT_CMDL_INFO
Karsten Hopp 7eee43
+     else
Karsten Hopp 7eee43
+ 	clear_showcmd();
Karsten Hopp 7eee43
+ #endif
Karsten Hopp 7eee43
+ }
Karsten Hopp 7eee43
+ 
Karsten Hopp 7eee43
  #if defined(FEAT_CMDL_INFO) || defined(PROTO)
Karsten Hopp 7eee43
  /*
Karsten Hopp 7eee43
   * Routines for displaying a partly typed command
Karsten Hopp 7eee43
***************
Karsten Hopp 7eee43
*** 4240,4245 ****
Karsten Hopp 7eee43
--- 4245,4251 ----
Karsten Hopp 7eee43
      cmdarg_T	*cap;
Karsten Hopp 7eee43
  {
Karsten Hopp 7eee43
      int visual = VIsual_active;
Karsten Hopp 7eee43
+ 
Karsten Hopp 7eee43
      if (cap->oap->op_type == OP_NOP
Karsten Hopp 7eee43
  	    && do_addsub((int)cap->cmdchar, cap->count1, cap->arg) == OK)
Karsten Hopp 7eee43
      {
Karsten Hopp 7eee43
***************
Karsten Hopp 7eee43
*** 4259,4264 ****
Karsten Hopp 7eee43
--- 4265,4271 ----
Karsten Hopp 7eee43
      {
Karsten Hopp 7eee43
  	VIsual_active = FALSE;
Karsten Hopp 7eee43
  	redo_VIsual_busy = FALSE;
Karsten Hopp 7eee43
+ 	may_clear_cmdline();
Karsten Hopp 7eee43
  	redraw_later(INVERTED);
Karsten Hopp 7eee43
      }
Karsten Hopp 7eee43
  }
Karsten Hopp 7eee43
*** ../vim-7.4.806/src/version.c	2015-08-04 18:23:16.538332360 +0200
Karsten Hopp 7eee43
--- src/version.c	2015-08-04 19:11:33.805670860 +0200
Karsten Hopp 7eee43
***************
Karsten Hopp 7eee43
*** 743,744 ****
Karsten Hopp 7eee43
--- 743,746 ----
Karsten Hopp 7eee43
  {   /* Add new patch number below this line */
Karsten Hopp 7eee43
+ /**/
Karsten Hopp 7eee43
+     807,
Karsten Hopp 7eee43
  /**/
Karsten Hopp 7eee43
Karsten Hopp 7eee43
-- 
Karsten Hopp 7eee43
LAUNCELOT: At last!   A call!  A cry of distress ...
Karsten Hopp 7eee43
           (he draws his sword, and turns to CONCORDE)
Karsten Hopp 7eee43
           Concorde!  Brave, Concorde ... you shall not have died in vain!
Karsten Hopp 7eee43
CONCORDE:  I'm not quite dead, sir ...
Karsten Hopp 7eee43
                 "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD
Karsten Hopp 7eee43
Karsten Hopp 7eee43
 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net   \\\
Karsten Hopp 7eee43
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
Karsten Hopp 7eee43
\\\  an exciting new programming language -- http://www.Zimbu.org        ///
Karsten Hopp 7eee43
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///