summaryrefslogtreecommitdiff
path: root/data/vim/patches/8.1.0328
blob: c5e957ffcb4be9be48677faeb48cb7bf4a77cc79 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
To: vim_dev@googlegroups.com
Subject: Patch 8.1.0328
Fcc: outbox
From: Bram Moolenaar <Bram@moolenaar.net>
Mime-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
------------

Patch 8.1.0328
Problem:    inputlist() doesn't work with a timer. (Dominique Pelle)
Solution:   Don't redraw when cmdline_row is zero. (Hirohito Higashi,
            closes #3239)
Files:	    src/misc1.c, src/screen.c


*** ../vim-8.1.0327/src/misc1.c	2018-08-21 15:12:10.839801647 +0200
--- src/misc1.c	2018-08-26 21:18:04.834809910 +0200
***************
*** 3747,3764 ****
      else
  	MSG_PUTS(_("Type number and <Enter> (empty cancels): "));
  
!     /* Set the state such that text can be selected/copied/pasted and we still
!      * get mouse events. */
      save_cmdline_row = cmdline_row;
      cmdline_row = 0;
      save_State = State;
!     State = ASKMORE;	/* prevents a screen update when using a timer */
  #ifdef FEAT_MOUSE
!     /* May show different mouse shape. */
      setmouse();
  #endif
  
- 
      i = get_number(TRUE, mouse_used);
      if (KeyTyped)
      {
--- 3747,3764 ----
      else
  	MSG_PUTS(_("Type number and <Enter> (empty cancels): "));
  
!     // Set the state such that text can be selected/copied/pasted and we still
!     // get mouse events. redraw_after_callback() will not redraw if cmdline_row
!     // is zero.
      save_cmdline_row = cmdline_row;
      cmdline_row = 0;
      save_State = State;
!     State = CMDLINE;
  #ifdef FEAT_MOUSE
!     // May show different mouse shape.
      setmouse();
  #endif
  
      i = get_number(TRUE, mouse_used);
      if (KeyTyped)
      {
***************
*** 3773,3779 ****
  	cmdline_row = save_cmdline_row;
      State = save_State;
  #ifdef FEAT_MOUSE
!     /* May need to restore mouse shape. */
      setmouse();
  #endif
  
--- 3773,3779 ----
  	cmdline_row = save_cmdline_row;
      State = save_State;
  #ifdef FEAT_MOUSE
!     // May need to restore mouse shape.
      setmouse();
  #endif
  
*** ../vim-8.1.0327/src/screen.c	2018-08-11 16:40:39.068311966 +0200
--- src/screen.c	2018-08-26 21:19:58.221890668 +0200
***************
*** 447,478 ****
      ++redrawing_for_callback;
  
      if (State == HITRETURN || State == ASKMORE)
! 	; /* do nothing */
      else if (State & CMDLINE)
      {
! 	/* Redrawing only works when the screen didn't scroll. Don't clear
! 	 * wildmenu entries. */
! 	if (msg_scrolled == 0
  #ifdef FEAT_WILDMENU
! 		&& wild_menu_showing == 0
  #endif
! 		&& call_update_screen)
! 	    update_screen(0);
! 	/* Redraw in the same position, so that the user can continue
! 	 * editing the command. */
! 	redrawcmdline_ex(FALSE);
      }
      else if (State & (NORMAL | INSERT | TERMINAL))
      {
! 	/* keep the command line if possible */
  	update_screen(VALID_NO_UPDATE);
  	setcursor();
      }
      cursor_on();
  #ifdef FEAT_GUI
      if (gui.in_use && !gui_mch_is_blink_off())
! 	/* Don't update the cursor when it is blinking and off to avoid
! 	 * flicker. */
  	out_flush_cursor(FALSE, FALSE);
      else
  #endif
--- 447,483 ----
      ++redrawing_for_callback;
  
      if (State == HITRETURN || State == ASKMORE)
! 	; // do nothing
      else if (State & CMDLINE)
      {
! 	// Don't redraw when in prompt_for_number().
! 	if (cmdline_row > 0)
! 	{
! 	    // Redrawing only works when the screen didn't scroll. Don't clear
! 	    // wildmenu entries.
! 	    if (msg_scrolled == 0
  #ifdef FEAT_WILDMENU
! 		    && wild_menu_showing == 0
  #endif
! 		    && call_update_screen)
! 		update_screen(0);
! 
! 	    // Redraw in the same position, so that the user can continue
! 	    // editing the command.
! 	    redrawcmdline_ex(FALSE);
! 	}
      }
      else if (State & (NORMAL | INSERT | TERMINAL))
      {
! 	// keep the command line if possible
  	update_screen(VALID_NO_UPDATE);
  	setcursor();
      }
      cursor_on();
  #ifdef FEAT_GUI
      if (gui.in_use && !gui_mch_is_blink_off())
! 	// Don't update the cursor when it is blinking and off to avoid
! 	// flicker.
  	out_flush_cursor(FALSE, FALSE);
      else
  #endif
*** ../vim-8.1.0327/src/version.c	2018-08-24 22:07:54.094796047 +0200
--- src/version.c	2018-08-26 21:16:30.423572538 +0200
***************
*** 796,797 ****
--- 796,799 ----
  {   /* Add new patch number below this line */
+ /**/
+     328,
  /**/

-- 
The budget process was invented by an alien race of sadistic beings who
resemble large cats.
				(Scott Adams - The Dilbert principle)

 /// Bram Moolenaar -- Bram@Moolenaar.net -- 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    ///