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

renamed completion.exTabCompletion() completion.ex()

This commit is contained in:
Martin Stubenschrott
2008-06-08 04:47:29 +00:00
parent 1c9f74b82d
commit 4a81ae7b11
3 changed files with 7 additions and 6 deletions

View File

@@ -568,9 +568,8 @@ liberator.Completion = function () //{{{
return false;
},
// FIXME: rename
// TODO: get completions for "nested" command lines like ":time :js <tab>" or ":tab :he<tab>"
exTabCompletion: function (str)
// provides completions for ex commands, including their arguments
ex: function (str)
{
substrings = [];
var [count, cmd, special, args] = liberator.commands.parseCommand(str);

View File

@@ -355,7 +355,7 @@ const liberator = (function () //{{{
completer: function (filter)
{
if (/^:/.test(filter))
return liberator.completion.exTabCompletion(filter);
return liberator.completion.ex(filter);
else
return liberator.completion.javascript(filter);
}
@@ -859,7 +859,7 @@ const liberator = (function () //{{{
// TODO: move elsewhere
liberator.registerCallback("submit", liberator.modes.EX, function (command) { liberator.execute(command); });
liberator.registerCallback("complete", liberator.modes.EX, function (str) { return liberator.completion.exTabCompletion(str); });
liberator.registerCallback("complete", liberator.modes.EX, function (str) { return liberator.completion.ex(str); });
// first time intro message
if (liberator.options.getPref("extensions." + liberator.config.name.toLowerCase() + ".firsttime", true))

View File

@@ -271,7 +271,9 @@ liberator.Tabs = function () //{{{
liberator.execute(args);
liberator.forceNewTab = false;
},
{ completer: function (filter) { return liberator.completion.exTabCompletion(filter); } });
{
completer: function (filter) { return liberator.completion.ex(filter); }
});
liberator.commands.add(["tabl[ast]"],
"Switch to the last tab",