mirror of
https://github.com/gryf/pentadactyl-pm.git
synced 2026-01-08 17:44:14 +01:00
NEWS updates and whitespace fixes.
This commit is contained in:
@@ -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;
|
||||
|
||||
@@ -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"]
|
||||
});
|
||||
|
||||
@@ -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"]
|
||||
|
||||
@@ -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))
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
"use strict";
|
||||
|
||||
Components.utils.import("resource://dactyl/base.jsm");
|
||||
defmodule("services", this, {
|
||||
defmodule("services", {
|
||||
exports: ["Services", "services"]
|
||||
});
|
||||
|
||||
|
||||
@@ -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"]
|
||||
});
|
||||
|
||||
@@ -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))
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
"use strict";
|
||||
|
||||
Components.utils.import("resource://dactyl/base.jsm");
|
||||
defmodule("template", this, {
|
||||
defmodule("template", {
|
||||
exports: ["Template", "template"],
|
||||
require: ["util"]
|
||||
});
|
||||
|
||||
@@ -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"]
|
||||
|
||||
Reference in New Issue
Block a user