1
0
mirror of https://github.com/gryf/pentadactyl-pm.git synced 2026-02-01 06:05:44 +01:00

Fix mode name generated for longer names in mapping serialization. Closes issue #565.

--HG--
extra : rebase_source : 115073fae6cf2a15692cac72df976e1eacf5298e
This commit is contained in:
Kris Maglione
2011-06-11 13:45:30 -04:00
parent c4c0ab7789
commit 3cc9ce2f8c
7 changed files with 40 additions and 16 deletions

View File

@@ -663,7 +663,9 @@ var Mappings = Module("mappings", {
function uniqueModes(modes) {
let chars = [k for ([k, v] in Iterator(modules.modes.modeChars))
if (v.every(function (mode) modes.indexOf(mode) >= 0))];
return array.uniq(modes.filter(function (m) chars.indexOf(m.char) < 0).concat(chars));
return array.uniq(modes.filter(function (m) chars.indexOf(m.char) < 0)
.map(function (m) m.name.toLowerCase())
.concat(chars));
}
commands.add(["feedkeys", "fk"],