mirror of
https://github.com/MidnightCommander/mc
synced 2025-01-08 20:41:59 +03:00
Merge branch '2586_mcedit_extended_keybindings'
* 2586_mcedit_extended_keybindings: Changed type of WEdit::extmod from integer to gboolean. Extended shortcuts like 'ctrl-x x' are unavailable in editor. Ticket #2586: broken extended keybindings in editor.
This commit is contained in:
commit
eb13abc437
@ -331,7 +331,7 @@ SelectCodepage = alt-e
|
||||
Options =
|
||||
OptionsSaveMode =
|
||||
LearnKeys =
|
||||
ExtendedKeyMap = ctrl-x
|
||||
ExtendedKeyMap =
|
||||
|
||||
[viewer]
|
||||
Help = f1
|
||||
|
@ -132,7 +132,7 @@ struct WEdit
|
||||
|
||||
/* line break */
|
||||
LineBreaks lb;
|
||||
int extmod;
|
||||
gboolean extmod;
|
||||
|
||||
char *labels[10];
|
||||
|
||||
|
@ -4160,7 +4160,7 @@ edit_execute_cmd (WEdit * edit, unsigned long command, int char_for_insertion)
|
||||
edit_begin_end_repeat_cmd (edit);
|
||||
break;
|
||||
case CK_ExtendedKeyMap:
|
||||
edit->extmod = 1;
|
||||
edit->extmod = TRUE;
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
|
@ -79,7 +79,7 @@ edit_translate_key (WEdit * edit, long x_key, int *cmd, int *ch)
|
||||
int c;
|
||||
|
||||
/* an ordinary insertable character */
|
||||
if (x_key < 256)
|
||||
if (!edit->extmod && x_key < 256)
|
||||
{
|
||||
#ifdef HAVE_CHARSET
|
||||
if (edit->charpoint >= 4)
|
||||
@ -183,7 +183,7 @@ edit_translate_key (WEdit * edit, long x_key, int *cmd, int *ch)
|
||||
/* Commands specific to the key emulation */
|
||||
if (edit->extmod)
|
||||
{
|
||||
edit->extmod = 0;
|
||||
edit->extmod = FALSE;
|
||||
command = keybind_lookup_keymap_command (editor_x_map, x_key);
|
||||
}
|
||||
else
|
||||
|
Loading…
Reference in New Issue
Block a user