]>
Commit | Line | Data |
---|---|---|
e7d66cb1 AM |
1 | To: vim-dev@vim.org |
2 | Subject: Patch 7.2.431 | |
3 | Fcc: outbox | |
4 | From: Bram Moolenaar <Bram@moolenaar.net> | |
5 | Mime-Version: 1.0 | |
6 | Content-Type: text/plain; charset=UTF-8 | |
7 | Content-Transfer-Encoding: 8bit | |
8 | ------------ | |
9 | ||
10 | Patch 7.2.431 | |
11 | Problem: ":amenu" moves the cursor when in Insert mode. | |
12 | Solution: Use CTRL-\ CTRL-O instead of CTRL-O. (Christian Brabandt) | |
13 | Files: src/menu.c | |
14 | ||
15 | ||
16 | *** ../vim-7.2.430/src/menu.c 2009-05-17 13:30:58.000000000 +0200 | |
17 | --- src/menu.c 2010-05-14 21:18:00.000000000 +0200 | |
18 | *************** | |
19 | *** 490,495 **** | |
20 | --- 490,496 ---- | |
21 | char_u *next_name; | |
22 | int i; | |
23 | int c; | |
24 | + int d; | |
25 | #ifdef FEAT_GUI | |
26 | int idx; | |
27 | int new_idx; | |
28 | *************** | |
29 | *** 746,751 **** | |
30 | --- 747,753 ---- | |
31 | * Don't do this if adding a tearbar (addtearoff == FALSE). | |
32 | * Don't do this for "<Nop>". */ | |
33 | c = 0; | |
34 | + d = 0; | |
35 | if (amenu && call_data != NULL && *call_data != NUL | |
36 | #ifdef FEAT_GUI_W32 | |
37 | && addtearoff | |
38 | *************** | |
39 | *** 761,778 **** | |
40 | c = Ctrl_C; | |
41 | break; | |
42 | case MENU_INSERT_MODE: | |
43 | ! c = Ctrl_O; | |
44 | break; | |
45 | } | |
46 | } | |
47 | ||
48 | ! if (c) | |
49 | { | |
50 | ! menu->strings[i] = alloc((unsigned)(STRLEN(call_data) + 4)); | |
51 | if (menu->strings[i] != NULL) | |
52 | { | |
53 | menu->strings[i][0] = c; | |
54 | ! STRCPY(menu->strings[i] + 1, call_data); | |
55 | if (c == Ctrl_C) | |
56 | { | |
57 | int len = (int)STRLEN(menu->strings[i]); | |
58 | --- 763,787 ---- | |
59 | c = Ctrl_C; | |
60 | break; | |
61 | case MENU_INSERT_MODE: | |
62 | ! c = Ctrl_BSL; | |
63 | ! d = Ctrl_O; | |
64 | break; | |
65 | } | |
66 | } | |
67 | ||
68 | ! if (c != 0) | |
69 | { | |
70 | ! menu->strings[i] = alloc((unsigned)(STRLEN(call_data) + 5 )); | |
71 | if (menu->strings[i] != NULL) | |
72 | { | |
73 | menu->strings[i][0] = c; | |
74 | ! if (d == 0) | |
75 | ! STRCPY(menu->strings[i] + 1, call_data); | |
76 | ! else | |
77 | ! { | |
78 | ! menu->strings[i][1] = d; | |
79 | ! STRCPY(menu->strings[i] + 2, call_data); | |
80 | ! } | |
81 | if (c == Ctrl_C) | |
82 | { | |
83 | int len = (int)STRLEN(menu->strings[i]); | |
84 | *** ../vim-7.2.430/src/version.c 2010-05-14 20:41:00.000000000 +0200 | |
85 | --- src/version.c 2010-05-14 21:11:40.000000000 +0200 | |
86 | *************** | |
87 | *** 683,684 **** | |
88 | --- 683,686 ---- | |
89 | { /* Add new patch number below this line */ | |
90 | + /**/ | |
91 | + 431, | |
92 | /**/ | |
93 | ||
94 | -- | |
95 | Despite the cost of living, have you noticed how it remains so popular? | |
96 | ||
97 | /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ | |
98 | /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ | |
99 | \\\ download, build and distribute -- http://www.A-A-P.org /// | |
100 | \\\ help me help AIDS victims -- http://ICCF-Holland.org /// |