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
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
|
To: vim_dev@googlegroups.com
Subject: Patch 8.1.1408
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.1408
Problem: PFL_HIDDEN conflicts with system header file.
Solution: Rename to POPF_HIDDEN.
Files: src/popupwin.c, src/screen.c, src/vim.h
*** ../vim-8.1.1407/src/popupwin.c 2019-05-26 23:32:03.175678045 +0200
--- src/popupwin.c 2019-05-27 10:02:28.387158316 +0200
***************
*** 300,309 ****
win_T *wp;
for (wp = first_popupwin; wp != NULL; wp = wp->w_next)
! if ((wp->w_popup_flags & PFL_HIDDEN) == 0)
return TRUE;
for (wp = curtab->tp_first_popupwin; wp != NULL; wp = wp->w_next)
! if ((wp->w_popup_flags & PFL_HIDDEN) == 0)
return TRUE;
return FALSE;
}
--- 300,309 ----
win_T *wp;
for (wp = first_popupwin; wp != NULL; wp = wp->w_next)
! if ((wp->w_popup_flags & POPF_HIDDEN) == 0)
return TRUE;
for (wp = curtab->tp_first_popupwin; wp != NULL; wp = wp->w_next)
! if ((wp->w_popup_flags & POPF_HIDDEN) == 0)
return TRUE;
return FALSE;
}
***************
*** 328,336 ****
int id = (int)tv_get_number(argvars);
win_T *wp = find_popup_win(id);
! if (wp != NULL && (wp->w_popup_flags & PFL_HIDDEN) == 0)
{
! wp->w_popup_flags |= PFL_HIDDEN;
redraw_all_later(NOT_VALID);
}
}
--- 328,336 ----
int id = (int)tv_get_number(argvars);
win_T *wp = find_popup_win(id);
! if (wp != NULL && (wp->w_popup_flags & POPF_HIDDEN) == 0)
{
! wp->w_popup_flags |= POPF_HIDDEN;
redraw_all_later(NOT_VALID);
}
}
***************
*** 344,352 ****
int id = (int)tv_get_number(argvars);
win_T *wp = find_popup_win(id);
! if (wp != NULL && (wp->w_popup_flags & PFL_HIDDEN) != 0)
{
! wp->w_popup_flags &= ~PFL_HIDDEN;
redraw_all_later(NOT_VALID);
}
}
--- 344,352 ----
int id = (int)tv_get_number(argvars);
win_T *wp = find_popup_win(id);
! if (wp != NULL && (wp->w_popup_flags & POPF_HIDDEN) != 0)
{
! wp->w_popup_flags &= ~POPF_HIDDEN;
redraw_all_later(NOT_VALID);
}
}
*** ../vim-8.1.1407/src/screen.c 2019-05-26 23:32:03.175678045 +0200
--- src/screen.c 2019-05-27 10:03:06.838940720 +0200
***************
*** 999,1007 ****
// Reset all the VALID_POPUP flags.
for (wp = first_popupwin; wp != NULL; wp = wp->w_next)
! wp->w_popup_flags &= ~PFL_REDRAWN;
for (wp = curtab->tp_first_popupwin; wp != NULL; wp = wp->w_next)
! wp->w_popup_flags &= ~PFL_REDRAWN;
// TODO: don't redraw every popup every time.
for (;;)
--- 999,1007 ----
// Reset all the VALID_POPUP flags.
for (wp = first_popupwin; wp != NULL; wp = wp->w_next)
! wp->w_popup_flags &= ~POPF_REDRAWN;
for (wp = curtab->tp_first_popupwin; wp != NULL; wp = wp->w_next)
! wp->w_popup_flags &= ~POPF_REDRAWN;
// TODO: don't redraw every popup every time.
for (;;)
***************
*** 1012,1025 ****
lowest_zindex = INT_MAX;
lowest_wp = NULL;
for (wp = first_popupwin; wp != NULL; wp = wp->w_next)
! if ((wp->w_popup_flags & (PFL_REDRAWN|PFL_HIDDEN)) == 0
&& wp->w_zindex < lowest_zindex)
{
lowest_zindex = wp->w_zindex;
lowest_wp = wp;
}
for (wp = curtab->tp_first_popupwin; wp != NULL; wp = wp->w_next)
! if ((wp->w_popup_flags & (PFL_REDRAWN|PFL_HIDDEN)) == 0
&& wp->w_zindex < lowest_zindex)
{
lowest_zindex = wp->w_zindex;
--- 1012,1025 ----
lowest_zindex = INT_MAX;
lowest_wp = NULL;
for (wp = first_popupwin; wp != NULL; wp = wp->w_next)
! if ((wp->w_popup_flags & (POPF_REDRAWN|POPF_HIDDEN)) == 0
&& wp->w_zindex < lowest_zindex)
{
lowest_zindex = wp->w_zindex;
lowest_wp = wp;
}
for (wp = curtab->tp_first_popupwin; wp != NULL; wp = wp->w_next)
! if ((wp->w_popup_flags & (POPF_REDRAWN|POPF_HIDDEN)) == 0
&& wp->w_zindex < lowest_zindex)
{
lowest_zindex = wp->w_zindex;
***************
*** 1029,1035 ****
if (lowest_wp == NULL)
break;
win_update(lowest_wp);
! lowest_wp->w_popup_flags |= PFL_REDRAWN;
}
}
#endif
--- 1029,1035 ----
if (lowest_wp == NULL)
break;
win_update(lowest_wp);
! lowest_wp->w_popup_flags |= POPF_REDRAWN;
}
}
#endif
*** ../vim-8.1.1407/src/vim.h 2019-05-26 22:17:31.740314999 +0200
--- src/vim.h 2019-05-27 10:03:13.758901545 +0200
***************
*** 614,621 ****
#define VALID_TOPLINE 0x80 // w_topline is valid (for cursor position)
// Values for w_popup_flags.
! #define PFL_HIDDEN 1 // popup is not displayed
! #define PFL_REDRAWN 2 // popup was just redrawn
/*
* Terminal highlighting attribute bits.
--- 614,621 ----
#define VALID_TOPLINE 0x80 // w_topline is valid (for cursor position)
// Values for w_popup_flags.
! #define POPF_HIDDEN 1 // popup is not displayed
! #define POPF_REDRAWN 2 // popup was just redrawn
/*
* Terminal highlighting attribute bits.
*** ../vim-8.1.1407/src/version.c 2019-05-26 23:32:03.179678024 +0200
--- src/version.c 2019-05-27 10:04:19.022531903 +0200
***************
*** 769,770 ****
--- 769,772 ----
{ /* Add new patch number below this line */
+ /**/
+ 1408,
/**/
--
hundred-and-one symptoms of being an internet addict:
38. You wake up at 3 a.m. to go to the bathroom and stop and check your e-mail
on the way back to bed.
/// 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 ///
|