mirror of
https://github.com/gryf/pentadactyl-pm.git
synced 2025-12-23 08:08:00 +01:00
Merge default.
--HG-- branch : groups
This commit is contained in:
@@ -79,9 +79,11 @@ var ProcessorStack = Class("ProcessorStack", {
|
|||||||
Events.kill(this.events[this.events.length - 1]);
|
Events.kill(this.events[this.events.length - 1]);
|
||||||
|
|
||||||
if (result === Events.PASS || result === Events.ABORT) {
|
if (result === Events.PASS || result === Events.ABORT) {
|
||||||
dbg("REFEED: " + this.events.filter(function (e) e.getPreventDefault()).map(events.closure.toString).join(""));
|
let list = this.events.filter(function (e) e.getPreventDefault());
|
||||||
this.events.filter(function (e) e.getPreventDefault())
|
if (list.length)
|
||||||
.forEach(function (event, i) {
|
events.dbg("REFEED: " + list.map(events.closure.toString).join(""));
|
||||||
|
|
||||||
|
list.forEach(function (event, i) {
|
||||||
let elem = event.originalTarget;
|
let elem = event.originalTarget;
|
||||||
if (event.originalTarget) {
|
if (event.originalTarget) {
|
||||||
let doc = elem.ownerDocument || elem.document || elem;
|
let doc = elem.ownerDocument || elem.document || elem;
|
||||||
@@ -307,6 +309,8 @@ var EventHive = Class("EventHive", Group.Hive, {
|
|||||||
* @instance events
|
* @instance events
|
||||||
*/
|
*/
|
||||||
var Events = Module("events", {
|
var Events = Module("events", {
|
||||||
|
dbg: function () {},
|
||||||
|
|
||||||
init: function () {
|
init: function () {
|
||||||
const self = this;
|
const self = this;
|
||||||
|
|
||||||
|
|||||||
@@ -1012,7 +1012,7 @@ var Timer = Class("Timer", {
|
|||||||
|
|
||||||
notify: function (timer, force) {
|
notify: function (timer, force) {
|
||||||
try {
|
try {
|
||||||
if (util.rehashing || typeof util === "undefined" || !force && this.doneAt == 0)
|
if (loaded.util && util.rehashing || typeof util === "undefined" || !force && this.doneAt == 0)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
this._timer.cancel();
|
this._timer.cancel();
|
||||||
|
|||||||
@@ -36,6 +36,8 @@ var JavaScript = Module("javascript", {
|
|||||||
},
|
},
|
||||||
}),
|
}),
|
||||||
|
|
||||||
|
lazyInit: true,
|
||||||
|
|
||||||
newContext: function () this.modules.newContext(this.modules.userContext),
|
newContext: function () this.modules.newContext(this.modules.userContext),
|
||||||
|
|
||||||
get completers() JavaScript.completers, // For backward compatibility
|
get completers() JavaScript.completers, // For backward compatibility
|
||||||
|
|||||||
@@ -291,13 +291,13 @@ var Overlay = Module("Overlay", {
|
|||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
function frob(name) {
|
function frob(name) { (deferredInit[name] || []).forEach(call); }
|
||||||
// util.dump(" ======================== FROB " + name + " ======================== ");
|
|
||||||
(deferredInit[name] || []).forEach(call);
|
|
||||||
}
|
|
||||||
|
|
||||||
frob("init");
|
frob("init");
|
||||||
defineModule.modules.forEach(function ({ constructor: { className } }) {
|
defineModule.modules.forEach(function ({ lazyInit, constructor: { className } }) {
|
||||||
|
if (!lazyInit)
|
||||||
|
frob(className);
|
||||||
|
else
|
||||||
modules.__defineGetter__(className, function () {
|
modules.__defineGetter__(className, function () {
|
||||||
delete modules[className];
|
delete modules[className];
|
||||||
frob(className);
|
frob(className);
|
||||||
|
|||||||
@@ -483,7 +483,24 @@ var tests = {
|
|||||||
sanitize: {
|
sanitize: {
|
||||||
// Skip details for now.
|
// Skip details for now.
|
||||||
completions: [
|
completions: [
|
||||||
"",
|
["", function (context) ["all",
|
||||||
|
"cache",
|
||||||
|
"downloads",
|
||||||
|
"formdata",
|
||||||
|
"offlineapps",
|
||||||
|
"passwords",
|
||||||
|
"sessions",
|
||||||
|
"cookies",
|
||||||
|
"history",
|
||||||
|
"host",
|
||||||
|
"sitesettings",
|
||||||
|
"commandline",
|
||||||
|
"messages",
|
||||||
|
"macros",
|
||||||
|
"marks",
|
||||||
|
"options"
|
||||||
|
].every(function (item) context.allItems.items.some(function ({ text }) item == text))
|
||||||
|
],
|
||||||
"-",
|
"-",
|
||||||
"-host=",
|
"-host=",
|
||||||
"-timespan="
|
"-timespan="
|
||||||
|
|||||||
Reference in New Issue
Block a user