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

NEWS updates and whitespace fixes.

This commit is contained in:
Kris Maglione
2010-09-19 02:13:19 -04:00
parent a53edafac1
commit 72be646c5b
19 changed files with 57 additions and 50 deletions

View File

@@ -6,7 +6,7 @@ BUILD_DATE = $(shell date "+%Y/%m/%d %H:%M:%S")
BASE = $(TOP)/../common
GOOGLE_PROJ = dactyl
GOOGLE = https://$(GOOGLE_PROJ).googlecode.com/files
VERSION = $(shell sed -n 's/.*<em:version>\(.*\)<.*/\1/p' $(TOP)/install.rdf)
VERSION = $(shell sed -n 's/.*em:version\(>\|="\)\(.*\)["<].*/\2/p' $(TOP)/install.rdf)
LOCALEDIR = locale
DOC_FILES = $(wildcard $(LOCALEDIR)/*/*.xml)

View File

@@ -363,7 +363,7 @@ const Bookmarks = Module("bookmarks", {
completion.bookmark(context, args["-tags"]);
},
options: [tags,
{
{
names: ["-max", "-m"],
description: "The maximum number of items to list or open",
type: CommandOption.INT

View File

@@ -451,7 +451,7 @@ const CommandLine = Module("commandline", {
/**
* Displays the multi-line output of a command, preceded by the last
* executed ex command string.
*
*
* @param {XML} xml The output as an E4X XML object.
*/
commandOutput: function (xml) {
@@ -1532,14 +1532,14 @@ const CommandLine = Module("commandline", {
action: function (timespan, host) {
if (!host)
storage["history-search"].mutate("filter", function (item) !timespan.contains(item.timestamp));
storage["history-command"].mutate("filter", function (item)
storage["history-command"].mutate("filter", function (item)
!(timespan.contains(item.timestamp) && (!host || commands.hasDomain(item.value, host))));
}
});
// Delete history-like items from the commandline and messages on history purge
sanitizer.addItem("history", {
action: function (timespan, host) {
storage["history-command"].mutate("filter", function (item)
storage["history-command"].mutate("filter", function (item)
!(timespan.contains(item.timestamp) && (host ? commands.hasDomain(item.value, host) : item.privateData)));
commandline._messageHistory.filter(function (item) !timespan.contains(item.timestamp * 1000) ||
!item.domains && !item.privateData ||
@@ -1601,7 +1601,7 @@ const ItemList = Class("ItemList", {
if (this._container.collapsed)
this._div.style.minWidth = document.getElementById("dactyl-commandline").scrollWidth + "px";
this._minHeight = Math.max(this._minHeight,
this._minHeight = Math.max(this._minHeight,
this._win.scrollY + this._divNodes.completions.getBoundingClientRect().bottom);
if (this._container.collapsed)

View File

@@ -272,7 +272,7 @@ const Command = Class("Command", {
serialize: null,
/**
* @property {number} If this command takes another ex command as an
* argument, the index of that argument. Used in determining whether to
* argument, the index of that argument. Used in determining whether to
* purge the command from history when clearing private data.
*/
subCommand: null,
@@ -474,7 +474,7 @@ const Commands = Module("commands", {
},
/**
* Returns true if a command invocation contains a URL referring to the
* Returns true if a command invocation contains a URL referring to the
* domain 'host'.
*
* @param {string} command
@@ -494,7 +494,7 @@ const Commands = Module("commands", {
},
/**
* Returns true if a command invocation contains private data which should
* Returns true if a command invocation contains private data which should
* be cleared when purging private data.
*
* @param {string} command
@@ -1070,13 +1070,13 @@ const Commands = Module("commands", {
options: [
{ names: ["-bang"], description: "Command may be proceeded by a !" },
{ names: ["-count"], description: "Command may be preceeded by a count" },
{
names: ["-description"],
{
names: ["-description"],
description: "A user-visible description of the command",
type: CommandOption.STRING
}, {
}, {
// TODO: "E180: invalid complete value: " + arg
names: ["-complete"],
names: ["-complete"],
description: "The argument completion function",
completer: function (context) [[k, ""] for ([k, v] in Iterator(completeOptionMap))],
type: CommandOption.STRING,

View File

@@ -544,7 +544,7 @@ const Dactyl = Module("dactyl", {
body += <h2 xmlns={NS.uri} tag={context.INFO.@name + '-plugin'}>{context.INFO.@summary}</h2> +
context.INFO;
let help =
let help =
'<?xml version="1.0"?>\n' +
'<?xml-stylesheet type="text/xsl" href="chrome://dactyl/content/help.xsl"?>\n' +
'<!DOCTYPE document SYSTEM "chrome://dactyl/content/dactyl.dtd">\n' +
@@ -1419,7 +1419,7 @@ const Dactyl = Module("dactyl", {
///////////////////////////////////////////////////////////////////////////
if (typeof AddonManager == "undefined")
if (typeof AddonManager == "undefined")
modules.AddonManager = {
getAddonByID: function (id, callback) {
callback = callback || util.identity;
@@ -1518,7 +1518,7 @@ const Dactyl = Module("dactyl", {
};
///////////////////////////////////////////////////////////////////////////
function callResult(method) {
let args = Array.slice(arguments, 1);
return function (result) { result[method].apply(result, args) };

View File

@@ -78,7 +78,7 @@ const IO = Module("io", {
* @final
*/
File: Class("File", File, {
init: function init(path, checkCWD)
init: function init(path, checkCWD)
init.supercall(this, path, (arguments.length < 2 || checkCWD) && io.getCurrentDirectory())
}),
@@ -671,7 +671,7 @@ lookup:
// NOTE: Vim doesn't replace ! preceded by 2 or more backslashes and documents it - desirable?
// pass through a raw bang when escaped or substitute the last command
// This is an asinine and irritating feature when we have searchable
// command-line history. --Kris
if (options["banghist"])

View File

@@ -20,7 +20,8 @@
straightforward, but allows for any number of complex actions to be
executed, with full access to all of the internals of &dactyl.appname; and
&dactyl.host;. Both expression evaluation methods support sophisticated
expression completion, including option lists and descriptions thereof.
expression completion, including option lists and descriptions thereof,
along with paren matching and syntax error highlighting.
</p>
<item>

View File

@@ -22,7 +22,7 @@
<p>
&dactyl.appname; has a number of internal variables and switches which can be set to
achieve special effects. These options come in 5 forms:
achieve special effects. These options come in 8 forms:
</p>
<dl>

View File

@@ -17,7 +17,7 @@ let hasOwnProperty = objproto.hasOwnProperty;
if (!Object.create)
Object.create = function (proto, props) {
let obj = { __proto__: proto };
for (let k in properties(props || {}))
for (let k in properties(props || {}))
Object.defineProperty(obj, k, props[k]);
return obj;
};
@@ -82,7 +82,8 @@ if (!Object.keys)
let use = {};
let loaded = {};
let currentModule;
function defmodule(name, module, params) {
function defmodule(name, params) {
let module = Cu.getGlobalForObject ? Cu.getGlobalForObject(params) : params.__parent__;
module.NAME = name;
module.EXPORTED_SYMBOLS = params.exports || [];
defmodule.loadLog.push("defmodule " + name);
@@ -129,12 +130,12 @@ function require(obj, name, from) {
Cu.import("resource://dactyl/" + name + ".jsm", obj);
}
catch (e) {
dump("loading " + String.quote("resource://dactyl/" + name + ".jsm") + "\n");
dump("loading " + String.quote("resource://dactyl/" + name + ".jsm") + "\n");
dump(" " + e.fileName + ":" + e.lineNumber + ": " + e +"\n");
}
}
defmodule("base", this, {
defmodule("base", {
// sed -n 's/^(const|function) ([a-zA-Z0-9_]+).*/ "\2",/p' base.jsm | sort | fmt
exports: [
"Cc", "Ci", "Class", "Cr", "Cu", "Module", "Object", "Runnable",
@@ -347,7 +348,7 @@ function iter(obj) {
for (let i = 0; i < obj.length; i++)
yield [obj.name, obj];
})();
if (obj instanceof Ci.mozIStorageStatement)
if (obj instanceof Ci.mozIStorageStatement)
return (function (obj) {
while (obj.executeStep())
yield obj.row;

View File

@@ -5,7 +5,7 @@
"use strict";
Components.utils.import("resource://dactyl/base.jsm");
defmodule("bookmarkcache", this, {
defmodule("bookmarkcache", {
exports: ["Bookmark", "BookmarkCache", "Keyword", "bookmarkcache"],
require: ["services", "storage", "util"]
});

View File

@@ -5,7 +5,7 @@
"use strict";
Components.utils.import("resource://dactyl/base.jsm");
defmodule("highlight", this, {
defmodule("highlight", {
exports: ["Highlight", "Highlights", "highlight"],
require: ["services", "styles"],
use: ["template", "util"]

View File

@@ -15,7 +15,7 @@
// - finish 1.9.0 support if we're going to support sanitizing in Xulmus
Components.utils.import("resource://dactyl/base.jsm");
defmodule("sanitizer", this, {
defmodule("sanitizer", {
exports: ["Range", "Sanitizer", "sanitizer"],
require: ["services", "storage", "util"]
});
@@ -79,7 +79,7 @@ const Sanitizer = Module("sanitizer", tmp.Sanitizer, {
// Zoom level, ...
services.get("contentprefs").removeGroupedPrefs();
}
// "Never remember passwords" ...
for each (let domain in services.get("loginmanager").getAllDisabledHosts())
if (!host || util.isSubdomain(domain, host))

View File

@@ -5,7 +5,7 @@
"use strict";
Components.utils.import("resource://dactyl/base.jsm");
defmodule("services", this, {
defmodule("services", {
exports: ["Services", "services"]
});

View File

@@ -6,7 +6,7 @@
const myObject = Object;
Components.utils.import("resource://dactyl/base.jsm");
defmodule("storage", this, {
defmodule("storage", {
exports: ["File", "storage"],
require: ["services", "util"]
});

View File

@@ -5,7 +5,7 @@
"use strict";
Components.utils.import("resource://dactyl/base.jsm");
defmodule("styles", this, {
defmodule("styles", {
exports: ["Style", "Styles", "styles"],
require: ["services", "util"],
use: ["template"]
@@ -368,7 +368,7 @@ const Styles = Module("Styles", {
if (!cmd.filter || cmd.filter(sheet))];
},
}, {
names: ["-name", "-n"],
names: ["-name", "-n"],
type: modules.CommandOption.STRING,
completer: function () [[name, sheet.css]
for ([name, sheet] in Iterator(styles.userNames))

View File

@@ -5,7 +5,7 @@
"use strict";
Components.utils.import("resource://dactyl/base.jsm");
defmodule("template", this, {
defmodule("template", {
exports: ["Template", "template"],
require: ["util"]
});

View File

@@ -7,7 +7,7 @@
"use strict";
Components.utils.import("resource://dactyl/base.jsm");
defmodule("util", this, {
defmodule("util", {
exports: ["Math", "NS", "Util", "XHTML", "XUL", "util"],
require: ["services"],
use: ["highlight", "template"]

8
pentadactyl/NEWS Executable file → Normal file
View File

@@ -20,18 +20,24 @@
- Supports reverse incremental search.
* IMPORTANT: Plugins are now loaded from the 'plugins/'
directory in 'runtimepath' rather than 'plugin/'
* IMPORTANT: Single quotes no longer treat \s specially
* Replaced 'focuscontent' with 'strictfocus'
I.e., 'fo\o''bar' ≡ fo\o'bar
* Added 'altwildmode' and <A-Tab> commandline key binding
* Added 'banghist' option
* Added transliterated option to 'hintmatching'
* gf now toggles between source and content view.
The | key binding has been removed.
* :extadd now supports URLs.
* :extadd now supports remote URLs as well as local files on
Firefox 4.
* :open now only opens files beginning with /, ./, ../, or ~/
* 'complete' now defaults to slf but file completion only
triggers when the URL begins as above.
* Page zoom information is now shown in the status bar, and
change in zoom status no longer appears in :messages.
* Added ZO, ZI, ZM, and ZR as aliases for zO, zI, zM, and zR
* Completion list now behaves better when the multi-line output
window is displayed
* Major help system improvements:
- Plugins may now provide full-fledged ':help' documentation
- Add basic plugin authorship documentation

View File

@@ -1,21 +1,20 @@
<?xml version="1.0"?>
<RDF xmlns="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:em="http://www.mozilla.org/2004/em-rdf#">
<Description about="urn:mozilla:install-manifest">
<em:id>pentadactyl@dactyl.googlecode.com</em:id>
<em:name>Pentadactyl</em:name>
<em:version>1.0b1pre</em:version>
<em:description>Firefox for Vim and Links addicts</em:description>
<em:creator>Kris Maglione</em:creator>
<em:homepageURL>http://dactyl.sf.net/Pentadactyl</em:homepageURL>
<em:iconURL>chrome://pentadactyl/skin/icon.png</em:iconURL>
<em:optionsURL>chrome://dactyl/content/preferences.xul</em:optionsURL>
<Description about="urn:mozilla:install-manifest"
em:id="pentadactyl@dactyl.googlecode.com"
em:name="Pentadactyl"
em:version="1.0b1pre"
em:description="Firefox for Vim and Links addicts"
em:creator="Kris Maglione"
em:homepageURL="http://dactyl.sf.net/Pentadactyl"
em:iconURL="chrome://pentadactyl/skin/icon.png"
em:optionsURL="chrome://dactyl/content/preferences.xul">
<em:targetApplication>
<Description>
<em:id>{ec8030f7-c20a-464f-9b0e-13a3a9e97384}</em:id>
<em:minVersion>3.5</em:minVersion>
<em:maxVersion>4.0b7pre</em:maxVersion>
</Description>
<Description
em:id="{ec8030f7-c20a-464f-9b0e-13a3a9e97384}"
em:minVersion="3.5"
em:maxVersion="4.0b7pre"/>
</em:targetApplication>
</Description>
</RDF>