Hi vim_dev!
On So, 28 Mär 2010, Christian Brabandt wrote:
> <C-O>, but I suspect, there is a reason for that. In case it is not, I
> quickly hacked together this patch (attached), which seems to work.
Hm, I am not sure, why git included that stuff in eval.c into the patch.
This was supposed to be a fresh HEAD and I only modified menu.c So
resending a clean patch.
Mit freundlichen Grüßen
Christian
--
Altsein heißt für mich immer: Fünfzehn Jahre älter als ich.
-- Bernard Mannes Baruch
--
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
To unsubscribe from this group, send email to
vim_dev+unsubscribegooglegroups.com or reply to this email with the words
"REMOVE ME" as the subject.
--- a/src/menu.c Tue Mar 23 18:22:46 2010 +0100
+++ b/src/menu.c Sun Mar 28 14:24:34 2010 +0200
@@ -490,6 +490,7 @@
char_u *next_name;
int i;
int c;
+ int d;
#ifdef FEAT_GUI
int idx;
int new_idx;
@@ -746,6 +747,7 @@
* Don't do this if adding a tearbar (addtearoff == FALSE).
* Don't do this for "<Nop>". */
c = 0;
+ d = 0;
if (amenu && call_data != NULL && *call_data != NUL
#ifdef FEAT_GUI_W32
&& addtearoff
@@ -761,18 +763,26 @@
c = Ctrl_C;
break;
case MENU_INSERT_MODE:
- c = Ctrl_O;
+ c = Ctrl_BSL;
+ d = Ctrl_O;
break;
}
}
if (c)
{
- menu->strings[i] = alloc((unsigned)(STRLEN(call_data) + 4));
+ menu->strings[i] = alloc((unsigned)(STRLEN(call_data) + 5
));
if (menu->strings[i] != NULL)
{
- menu->strings[i][0] = c;
- STRCPY(menu->strings[i] + 1, call_data);
+
+ menu->strings[i][0] = c;
+ if (!d)
+ STRCPY(menu->strings[i] + 1, call_data);
+ else
+ {
+ menu->strings[i][1] = d;
+ STRCPY(menu->strings[i] + 2, call_data);
+ }
if (c == Ctrl_C)
{
int len = (int)STRLEN(menu->strings[i]);