Patch 8.0.1113
Problem:    Can go to Insert mode from Terminal-Normal mode.
Solution:   Prevent :startinsert and "VA" to enter Insert mode. (Yasuhiro
            Matsumoto, closes #2092)
Files:      src/normal.c


*** ../vim-8.0.1112/src/normal.c        2017-09-10 18:44:25.713358435 +0200
--- src/normal.c        2017-09-16 15:33:27.521013476 +0200
***************
*** 1309,1316 ****
  #endif
  
  #ifdef FEAT_TERMINAL
!     /* don't go to Insert mode from Terminal-Job mode */
!     if (term_use_loop())
        restart_edit = 0;
  #endif
  
--- 1309,1316 ----
  #endif
  
  #ifdef FEAT_TERMINAL
!     /* don't go to Insert mode if a terminal has a running job */
!     if (term_job_running(curbuf->b_term))
        restart_edit = 0;
  #endif
  
***************
*** 9044,9050 ****
--- 9044,9061 ----
  
      /* in Visual mode "A" and "I" are an operator */
      if (VIsual_active && (cap->cmdchar == 'A' || cap->cmdchar == 'I'))
+     {
+ #ifdef FEAT_TERMINAL
+       if (term_in_normal_mode())
+       {
+           end_visual_mode();
+           clearop(cap->oap);
+           term_enter_job_mode();
+           return;
+       }
+ #endif
        v_visop(cap);
+     }
  
      /* in Visual mode and after an operator "a" and "i" are for text objects 
*/
      else if ((cap->cmdchar == 'a' || cap->cmdchar == 'i')
*** ../vim-8.0.1112/src/version.c       2017-09-15 22:43:01.797323504 +0200
--- src/version.c       2017-09-16 15:37:40.007516623 +0200
***************
*** 771,772 ****
--- 771,774 ----
  {   /* Add new patch number below this line */
+ /**/
+     1113,
  /**/

-- 
Don't drink and drive.  You might hit a bump and spill your beer.

 /// Bram Moolenaar -- [email protected] -- http://www.Moolenaar.net   \\\
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\  an exciting new programming language -- http://www.Zimbu.org        ///
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Raspunde prin e-mail lui