]>
Commit | Line | Data |
---|---|---|
c0949972 ER |
1 | To: vim-dev@vim.org |
2 | Subject: patch 7.1.111 | |
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.1.111 | |
11 | Problem: When using ":vimgrep" with the "j" flag folds from another buffer | |
12 | may be displayed. (A.Politz) | |
13 | Solution: When not jumping to another buffer update the folds. | |
14 | Files: src/quickfix.c | |
15 | ||
16 | ||
17 | *** ../vim-7.1.110/src/quickfix.c Thu Jun 28 21:23:52 2007 | |
18 | --- src/quickfix.c Fri Sep 14 22:16:23 2007 | |
19 | *************** | |
20 | *** 1612,1619 **** | |
21 | } | |
22 | ||
23 | /* | |
24 | ! * If there is only one window and is the quickfix window, create a new | |
25 | ! * one above the quickfix window. | |
26 | */ | |
27 | if (((firstwin == lastwin) && bt_quickfix(curbuf)) || !usable_win) | |
28 | { | |
29 | --- 1612,1619 ---- | |
30 | } | |
31 | ||
32 | /* | |
33 | ! * If there is only one window and it is the quickfix window, create a | |
34 | ! * new one above the quickfix window. | |
35 | */ | |
36 | if (((firstwin == lastwin) && bt_quickfix(curbuf)) || !usable_win) | |
37 | { | |
38 | *************** | |
39 | *** 2981,2986 **** | |
40 | --- 2981,2987 ---- | |
41 | buf_T *buf; | |
42 | int duplicate_name = FALSE; | |
43 | int using_dummy; | |
44 | + int redraw_for_dummy = FALSE; | |
45 | int found_match; | |
46 | buf_T *first_match_buf = NULL; | |
47 | time_t seconds = 0; | |
48 | *************** | |
49 | *** 3097,3102 **** | |
50 | --- 3098,3104 ---- | |
51 | /* Remember that a buffer with this name already exists. */ | |
52 | duplicate_name = (buf != NULL); | |
53 | using_dummy = TRUE; | |
54 | + redraw_for_dummy = TRUE; | |
55 | ||
56 | #if defined(FEAT_AUTOCMD) && defined(FEAT_SYN_HL) | |
57 | /* Don't do Filetype autocommands to avoid loading syntax and | |
58 | *************** | |
59 | *** 3243,3252 **** | |
60 | --- 3245,3272 ---- | |
61 | if (qi->qf_lists[qi->qf_curlist].qf_count > 0) | |
62 | { | |
63 | if ((flags & VGR_NOJUMP) == 0) | |
64 | + { | |
65 | + buf = curbuf; | |
66 | qf_jump(qi, 0, 0, eap->forceit); | |
67 | + if (buf != curbuf) | |
68 | + /* If we jumped to another buffer redrawing will already be | |
69 | + * taken care of. */ | |
70 | + redraw_for_dummy = FALSE; | |
71 | + } | |
72 | } | |
73 | else | |
74 | EMSG2(_(e_nomatch2), s); | |
75 | + | |
76 | + /* If we loaded a dummy buffer into the current window, the autocommands | |
77 | + * may have messed up things, need to redraw and recompute folds. */ | |
78 | + if (redraw_for_dummy) | |
79 | + { | |
80 | + #ifdef FEAT_FOLDING | |
81 | + foldUpdateAll(curwin); | |
82 | + #else | |
83 | + redraw_later(NOT_VALID); | |
84 | + #endif | |
85 | + } | |
86 | ||
87 | theend: | |
88 | vim_free(regmatch.regprog); | |
89 | *** ../vim-7.1.110/src/version.c Sat Sep 15 14:48:57 2007 | |
90 | --- src/version.c Sun Sep 16 13:23:48 2007 | |
91 | *************** | |
92 | *** 668,669 **** | |
93 | --- 668,671 ---- | |
94 | { /* Add new patch number below this line */ | |
95 | + /**/ | |
96 | + 111, | |
97 | /**/ | |
98 | ||
99 | -- | |
100 | Trees moving back and forth is what makes the wind blow. | |
101 | ||
102 | /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ | |
103 | /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ | |
104 | \\\ download, build and distribute -- http://www.A-A-P.org /// | |
105 | \\\ help me help AIDS victims -- http://ICCF-Holland.org /// |