summaryrefslogtreecommitdiffstats
path: root/gvim/vim-7.2/7.2.103
blob: 25a513a752a18881f7773ca7a7681fbd9063280e (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
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
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
To: vim-dev@vim.org
Subject: Patch 7.2.103
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.2.103
Problem:    When 'bomb' is changed the window title is updated to show/hide a
	    "+", but the tab page label isn't. (Patrick Texier)
Solution:   Set "redraw_tabline" in most places where "need_maketitle" is set.
	    (partly by Lech Lorens)
Files:	    src/option.c


*** ../vim-7.2.102/src/option.c	Wed Feb  4 17:27:50 2009
--- src/option.c	Wed Feb  4 17:40:02 2009
***************
*** 5268,5273 ****
--- 5268,5288 ----
  }
  #endif
  
+ #ifdef FEAT_TITLE
+ static void redraw_titles __ARGS((void));
+ 
+ /*
+  * Redraw the window title and/or tab page text later.
+  */
+ static void redraw_titles()
+ {
+     need_maketitle = TRUE;
+ # ifdef FEAT_WINDOWS
+     redraw_tabline = TRUE;
+ # endif
+ }
+ #endif
+ 
  /*
   * Set a string option to a new value (without checking the effect).
   * The string is copied into allocated memory.
***************
*** 5672,5678 ****
  	    {
  # ifdef FEAT_TITLE
  		/* May show a "+" in the title now. */
! 		need_maketitle = TRUE;
  # endif
  		/* Add 'fileencoding' to the swap file. */
  		ml_setflags(curbuf);
--- 5687,5693 ----
  	    {
  # ifdef FEAT_TITLE
  		/* May show a "+" in the title now. */
! 		redraw_titles();
  # endif
  		/* Add 'fileencoding' to the swap file. */
  		ml_setflags(curbuf);
***************
*** 5691,5697 ****
  	    {
  		errmsg = mb_init();
  # ifdef FEAT_TITLE
! 		need_maketitle = TRUE;
  # endif
  	    }
  	}
--- 5706,5712 ----
  	    {
  		errmsg = mb_init();
  # ifdef FEAT_TITLE
! 		redraw_titles();
  # endif
  	    }
  	}
***************
*** 5800,5806 ****
  	    else
  		curbuf->b_p_tx = FALSE;
  #ifdef FEAT_TITLE
! 	    need_maketitle = TRUE;
  #endif
  	    /* update flag in swap file */
  	    ml_setflags(curbuf);
--- 5815,5821 ----
  	    else
  		curbuf->b_p_tx = FALSE;
  #ifdef FEAT_TITLE
! 	    redraw_titles();
  #endif
  	    /* update flag in swap file */
  	    ml_setflags(curbuf);
***************
*** 7127,7148 ****
  	    curbuf->b_did_warn = FALSE;
  
  #ifdef FEAT_TITLE
! 	need_maketitle = TRUE;
  #endif
      }
  
  #ifdef FEAT_TITLE
      /* when 'modifiable' is changed, redraw the window title */
      else if ((int *)varp == &curbuf->b_p_ma)
! 	need_maketitle = TRUE;
      /* when 'endofline' is changed, redraw the window title */
      else if ((int *)varp == &curbuf->b_p_eol)
! 	need_maketitle = TRUE;
! #ifdef FEAT_MBYTE
!     /* when 'bomb' is changed, redraw the window title */
      else if ((int *)varp == &curbuf->b_p_bomb)
! 	need_maketitle = TRUE;
! #endif
  #endif
  
      /* when 'bin' is set also set some other options */
--- 7142,7169 ----
  	    curbuf->b_did_warn = FALSE;
  
  #ifdef FEAT_TITLE
! 	redraw_titles();
  #endif
      }
  
  #ifdef FEAT_TITLE
      /* when 'modifiable' is changed, redraw the window title */
      else if ((int *)varp == &curbuf->b_p_ma)
!     {
! 	redraw_titles();
!     }
      /* when 'endofline' is changed, redraw the window title */
      else if ((int *)varp == &curbuf->b_p_eol)
!     {
! 	redraw_titles();
!     }
! # ifdef FEAT_MBYTE
!     /* when 'bomb' is changed, redraw the window title and tab page text */
      else if ((int *)varp == &curbuf->b_p_bomb)
!     {
! 	redraw_titles();
!     }
! # endif
  #endif
  
      /* when 'bin' is set also set some other options */
***************
*** 7150,7156 ****
      {
  	set_options_bin(old_value, curbuf->b_p_bin, opt_flags);
  #ifdef FEAT_TITLE
! 	need_maketitle = TRUE;
  #endif
      }
  
--- 7171,7177 ----
      {
  	set_options_bin(old_value, curbuf->b_p_bin, opt_flags);
  #ifdef FEAT_TITLE
! 	redraw_titles();
  #endif
      }
  
***************
*** 7301,7307 ****
  	if (!value)
  	    save_file_ff(curbuf);	/* Buffer is unchanged */
  #ifdef FEAT_TITLE
! 	need_maketitle = TRUE;
  #endif
  #ifdef FEAT_AUTOCMD
  	modified_was_set = value;
--- 7322,7328 ----
  	if (!value)
  	    save_file_ff(curbuf);	/* Buffer is unchanged */
  #ifdef FEAT_TITLE
! 	redraw_titles();
  #endif
  #ifdef FEAT_AUTOCMD
  	modified_was_set = value;
***************
*** 7736,7742 ****
  	newFoldLevel();
      }
  
!     /* 'foldminlevel' */
      else if (pp == &curwin->w_p_fml)
      {
  	foldUpdateAll(curwin);
--- 7757,7763 ----
  	newFoldLevel();
      }
  
!     /* 'foldminlines' */
      else if (pp == &curwin->w_p_fml)
      {
  	foldUpdateAll(curwin);
*** ../vim-7.2.102/src/version.c	Thu Feb  5 20:47:14 2009
--- src/version.c	Wed Feb 11 11:32:20 2009
***************
*** 678,679 ****
--- 678,681 ----
  {   /* Add new patch number below this line */
+ /**/
+     103,
  /**/

-- 
hundred-and-one symptoms of being an internet addict:
73. You give your dog used motherboards instead of bones

 /// 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    ///