1
0
mirror of https://github.com/gryf/pentadactyl-pm.git synced 2025-12-23 10:08:00 +01:00

rename variables named char as this is a reserved word

This commit is contained in:
Doug Kearns
2008-08-05 02:03:41 +00:00
parent 8a64e78d9e
commit 2a0c5ef869
2 changed files with 10 additions and 10 deletions

View File

@@ -149,12 +149,12 @@ liberator.Editor = function () //{{{
}
// mode = "i" -> add :iabbrev, :iabclear and :iunabbrev commands
function addAbbreviationCommands(char, modeDescription)
function addAbbreviationCommands(ch, modeDescription)
{
var modeDescription = modeDescription ? " in " + modeDescription + " mode" : "";
var mode = char || "!";
var mode = ch || "!";
liberator.commands.add([char ? char + "a[bbrev]" : "ab[breviate]"],
liberator.commands.add([ch ? ch + "a[bbrev]" : "ab[breviate]"],
"Abbreviate a key sequence" + modeDescription,
function (args)
{
@@ -172,11 +172,11 @@ liberator.Editor = function () //{{{
liberator.editor.listAbbreviations(mode, lhs);
});
liberator.commands.add([char ? char + "una[bbrev]" : "una[bbreviate]"],
liberator.commands.add([ch ? ch + "una[bbrev]" : "una[bbreviate]"],
"Remove an abbreviation" + modeDescription,
function (args) { liberator.editor.removeAbbreviation(mode, args); });
liberator.commands.add([char + "abc[lear]"],
liberator.commands.add([ch + "abc[lear]"],
"Remove all abbreviations" + modeDescription,
function (args) { liberator.editor.removeAllAbbreviations(mode); });
}

View File

@@ -164,7 +164,7 @@ liberator.Mappings = function () //{{{
throw StopIteration;
}
function addMapCommands(char, modes, modeDescription)
function addMapCommands(ch, modes, modeDescription)
{
// 0 args -> list all maps
// 1 arg -> list the maps starting with args
@@ -202,15 +202,15 @@ liberator.Mappings = function () //{{{
var modeDescription = modeDescription ? " in " + modeDescription + " mode" : "";
liberator.commands.add([char ? char + "m[ap]" : "map"],
liberator.commands.add([ch ? ch + "m[ap]" : "map"],
"Map a key sequence" + modeDescription,
function (args) { map(args, modes, false); });
liberator.commands.add([char + "no[remap]"],
liberator.commands.add([ch + "no[remap]"],
"Map a key sequence without remapping keys" + modeDescription,
function (args) { map(args, modes, true); });
liberator.commands.add([char + "mapc[lear]"],
liberator.commands.add([ch + "mapc[lear]"],
"Remove all mappings" + modeDescription,
function (args)
{
@@ -224,7 +224,7 @@ liberator.Mappings = function () //{{{
liberator.mappings.removeAll(modes[i]);
});
liberator.commands.add([char + "unm[ap]"],
liberator.commands.add([ch + "unm[ap]"],
"Remove a mapping" + modeDescription,
function (args)
{