1
0
mirror of https://github.com/gryf/pentadactyl-pm.git synced 2026-02-14 19:35:45 +01:00

Replace weird mystery meat args of mapping actions with a proper object.

This commit is contained in:
Kris Maglione
2010-12-29 22:21:00 -05:00
parent f67a50147e
commit cb97f1cd25
12 changed files with 87 additions and 98 deletions

View File

@@ -335,8 +335,7 @@ var Command = Class("Command", {
case "-keys":
let silent = args["-silent"];
rhs = events.canonicalKeys(rhs, true);
var action = function action(count) events.feedkeys(action.macro({ count: count || "" }),
noremap, silent);
var action = function action(args) events.feedkeys(action.macro(args), noremap, silent);
action.macro = util.compileMacro(rhs, true);
break;
case "-ex":
@@ -1527,9 +1526,9 @@ var Commands = Module("commands", {
mappings: function () {
mappings.add(config.browserModes,
["@:"], "Repeat the last Ex command",
function (count) {
function (args) {
if (commands.repeat) {
for (let i in util.interruptibleRange(0, Math.max(count, 1), 100))
for (let i in util.interruptibleRange(0, Math.max(args.count, 1), 100))
dactyl.execute(commands.repeat);
}
else