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:
@@ -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);
|
||||
|
||||
@@ -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))
|
||||
|
||||
@@ -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",
|
||||
|
||||
Reference in New Issue
Block a user