mirror of
https://github.com/gryf/pentadactyl-pm.git
synced 2026-02-05 08:45:46 +01:00
Don't add :*map commands multiple times.
Multiple modes may share the same mode character. E.g. Textarea and Insert modes.
This commit is contained in:
@@ -292,7 +292,7 @@ function Mappings() //{{{
|
||||
addMapCommands("", [modes.NORMAL, modes.VISUAL], "");
|
||||
|
||||
for (let mode in modes.mainModes)
|
||||
if (mode.char)
|
||||
if (mode.char && !commands.get(mode.char + "map"))
|
||||
addMapCommands(mode.char,
|
||||
[m.mask for (m in modes.mainModes) if (m.char == mode.char)],
|
||||
[mode.disp.toLowerCase()]);
|
||||
|
||||
Reference in New Issue
Block a user