From 7693ac50001e3c1c4326546f9957080338baefe1 Mon Sep 17 00:00:00 2001 From: Kris Maglione Date: Sun, 7 Dec 2008 10:48:03 -0500 Subject: [PATCH] Fix :time :stuff, etc. --- common/content/completion.js | 2 +- common/content/events.js | 2 +- common/content/hints.js | 2 +- common/content/io.js | 2 +- common/content/liberator.js | 12 ++++++------ common/content/liberator.xul | 2 +- common/content/modes.js | 9 ++++++--- common/content/template.js | 4 ++-- common/content/ui.js | 34 +++++++++++++--------------------- 9 files changed, 32 insertions(+), 37 deletions(-) diff --git a/common/content/completion.js b/common/content/completion.js index c2f2c0d0..11b7f407 100644 --- a/common/content/completion.js +++ b/common/content/completion.js @@ -1141,7 +1141,7 @@ function Completion() //{{{ context = context.contexts["/list"]; context.wait(); - let list = template.generic( + let list = template.commandOutput(
{ template.completionRow(context.title, "CompTitle") } { template.map(context.items, function (item) context.createRow(item), null, 100) } diff --git a/common/content/events.js b/common/content/events.js index 38449a05..7f0e47ab 100644 --- a/common/content/events.js +++ b/common/content/events.js @@ -207,7 +207,7 @@ function AutoCommands() //{{{ } }); - var list = template.generic( + var list = template.commandOutput( diff --git a/common/content/hints.js b/common/content/hints.js index 03c88bd3..fa39b97f 100644 --- a/common/content/hints.js +++ b/common/content/hints.js @@ -354,7 +354,7 @@ function Hints() //{{{ } hintNumber = 0; - hintString = commandline.getCommand(); + hintString = commandline.command; updateStatusline(); showHints(); if (validHints.length == 1) diff --git a/common/content/io.js b/common/content/io.js index 69f41f21..22156ffb 100644 --- a/common/content/io.js +++ b/common/content/io.js @@ -365,7 +365,7 @@ function IO() //{{{ let output = io.system(args); - commandline.echo(template.generic({output})); + commandline.commandOutput(template.commandOutput({output})); autocommands.trigger("ShellCmdPost", {}); }, diff --git a/common/content/liberator.js b/common/content/liberator.js index 2861bf0c..d48ed17b 100644 --- a/common/content/liberator.js +++ b/common/content/liberator.js @@ -475,7 +475,7 @@ const liberator = (function () //{{{ totalUnits = "msec"; } - var str = template.generic( + let str = template.commandOutput(
----- Auto Commands -----
@@ -528,7 +528,7 @@ const liberator = (function () //{{{ if (args.bang) liberator.open("about:"); else - liberator.echo(template.generic(<>{config.name} {liberator.version} running on:
{navigator.userAgent})); + liberator.echo(template.commandOutput(<>{config.name} {liberator.version} running on:
{navigator.userAgent})); }, { argCount: "0", @@ -850,10 +850,10 @@ const liberator = (function () //{{{ err = "E477: No ! allowed"; } - if (!err) - command.execute(args, special, count, modifiers); - else - liberator.echoerr(err); + if (err) + return liberator.echoerr(err); + commandline.command = str.replace(/^\s*:\s*/); + command.execute(args, special, count, modifiers); }, // TODO: move to buffer.focus()? diff --git a/common/content/liberator.xul b/common/content/liberator.xul index 3be74c0b..a2e67338 100644 --- a/common/content/liberator.xul +++ b/common/content/liberator.xul @@ -81,7 +81,7 @@ the terms of any one of the MPL, the GPL or the LGPL. -
Code execution summary