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

:macro for playing a macro added

This commit is contained in:
Marco Candrian
2008-01-21 12:58:22 +00:00
parent 7982265c98
commit 2b71bd70b8
4 changed files with 37 additions and 4 deletions

View File

@@ -1439,7 +1439,7 @@ vimperator.Commands = function () //{{{
completer: function (filter) { return vimperator.completion.autocommands(filter); }
}
));
commandManager.add(new vimperator.Command(["mac[ros]"],
commandManager.add(new vimperator.Command(["macros"],
function (arg)
{
var str = "<table>";
@@ -1472,6 +1472,21 @@ vimperator.Commands = function () //{{{
help: "Delete recorded macros matching a regular expression."
}
));
commandManager.add(new vimperator.Command(["mac[ro]"],
function (arg)
{
if (!arg)
vimperator.echoerr("E474: Invalid argument");
else
vimperator.events.playMacro(arg);
},
{
usage: ["delmac[ros] [regex]"],
shortHelp: "Delete macros matching a regex",
help: "Delete recorded macros matching a regular expression.",
completer: function (filter) { return vimperator.completion.macros(filter); }
}
));
// 0 args -> list all maps
// 1 arg -> list the maps starting with args
// 2 args -> map arg1 to arg*