]>
Commit | Line | Data |
---|---|---|
f3c378e8 AG |
1 | To: vim-dev@vim.org |
2 | Subject: Patch 7.0.097 | |
3 | Fcc: outbox | |
4 | From: Bram Moolenaar <Bram@moolenaar.net> | |
5 | Mime-Version: 1.0 | |
6 | Content-Type: text/plain; charset=ISO-8859-1 | |
7 | Content-Transfer-Encoding: 8bit | |
8 | ------------ | |
9 | ||
10 | Patch 7.0.097 | |
11 | Problem: ":tabclose N" that closes another tab page does not remove the tab | |
12 | pages line. Same problem when using the mouse. | |
13 | Solution: Adjust the tab pages line when needed in tabpage_close_other(). | |
14 | Files: src/ex_docmd.c | |
15 | ||
16 | ||
17 | *** ../vim-7.0.096/src/ex_docmd.c Tue Aug 29 17:28:56 2006 | |
18 | --- src/ex_docmd.c Sun Sep 10 15:47:33 2006 | |
19 | *************** | |
20 | *** 6296,6302 **** | |
21 | exarg_T *eap; | |
22 | { | |
23 | tabpage_T *tp; | |
24 | - int h = tabline_height(); | |
25 | ||
26 | # ifdef FEAT_CMDWIN | |
27 | if (cmdwin_type != 0) | |
28 | --- 6296,6301 ---- | |
29 | *************** | |
30 | *** 6328,6336 **** | |
31 | ) | |
32 | tabpage_close(eap->forceit); | |
33 | } | |
34 | - | |
35 | - if (h != tabline_height()) | |
36 | - shell_new_rows(); | |
37 | } | |
38 | ||
39 | /* | |
40 | --- 6327,6332 ---- | |
41 | *************** | |
42 | *** 6342,6348 **** | |
43 | { | |
44 | tabpage_T *tp; | |
45 | int done; | |
46 | - int h = tabline_height(); | |
47 | ||
48 | # ifdef FEAT_CMDWIN | |
49 | if (cmdwin_type != 0) | |
50 | --- 6338,6343 ---- | |
51 | *************** | |
52 | *** 6371,6379 **** | |
53 | break; | |
54 | } | |
55 | } | |
56 | - | |
57 | - if (h != tabline_height()) | |
58 | - shell_new_rows(); | |
59 | } | |
60 | ||
61 | /* | |
62 | --- 6366,6371 ---- | |
63 | *************** | |
64 | *** 6397,6402 **** | |
65 | --- 6389,6396 ---- | |
66 | /* | |
67 | * Close tab page "tp", which is not the current tab page. | |
68 | * Note that autocommands may make "tp" invalid. | |
69 | + * Also takes care of the tab pages line disappearing when closing the | |
70 | + * last-but-one tab page. | |
71 | */ | |
72 | void | |
73 | tabpage_close_other(tp, forceit) | |
74 | *************** | |
75 | *** 6405,6410 **** | |
76 | --- 6399,6405 ---- | |
77 | { | |
78 | int done = 0; | |
79 | win_T *wp; | |
80 | + int h = tabline_height(); | |
81 | ||
82 | /* Limit to 1000 windows, autocommands may add a window while we close | |
83 | * one. OK, so I'm paranoid... */ | |
84 | *************** | |
85 | *** 6418,6424 **** | |
86 | --- 6413,6422 ---- | |
87 | if (!valid_tabpage(tp) || tp->tp_firstwin == wp) | |
88 | break; | |
89 | } | |
90 | + | |
91 | redraw_tabline = TRUE; | |
92 | + if (h != tabline_height()) | |
93 | + shell_new_rows(); | |
94 | } | |
95 | ||
96 | /* | |
97 | *** ../vim-7.0.096/src/version.c Sun Sep 10 13:56:06 2006 | |
98 | --- src/version.c Sun Sep 10 15:44:24 2006 | |
99 | *************** | |
100 | *** 668,669 **** | |
101 | --- 668,671 ---- | |
102 | { /* Add new patch number below this line */ | |
103 | + /**/ | |
104 | + 97, | |
105 | /**/ | |
106 | ||
107 | -- | |
108 | Advice to worms: Sleep late. | |
109 | ||
110 | /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ | |
111 | /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ | |
112 | \\\ download, build and distribute -- http://www.A-A-P.org /// | |
113 | \\\ help me help AIDS victims -- http://ICCF-Holland.org /// |