mirror of
https://github.com/gryf/pentadactyl-pm.git
synced 2025-12-20 05:58:03 +01:00
Remove beforeunload handler.
This commit is contained in:
@@ -290,7 +290,6 @@ var CommandWidgets = Class("CommandWidgets", {
|
||||
}),
|
||||
|
||||
multilineOutput: Class.Memoize(function () this._whenReady("dactyl-multiline-output", function (elem) {
|
||||
elem.contentWindow.addEventListener("beforeunload", function (event) { event.preventDefault(); }, true);
|
||||
highlight.highlightNode(elem.contentDocument.body, "MOW");
|
||||
}), true),
|
||||
|
||||
|
||||
@@ -381,13 +381,23 @@ var Util = Module("Util", XPCOM([Ci.nsIObserver, Ci.nsISupportsWeakReference]),
|
||||
if (idx) {
|
||||
idx = Number(idx) - 1;
|
||||
stack.top.elements.push(update(
|
||||
function (obj) obj[name] != null && idx in obj[name] ? quote(obj[name][idx]) : Set.has(obj, name) ? "" : unknown(full),
|
||||
{ test: function (obj) obj[name] != null && idx in obj[name] && obj[name][idx] !== false && (!flags.e || obj[name][idx] != "") }));
|
||||
function (obj) obj[name] != null && idx in obj[name] ? quote(obj[name][idx])
|
||||
: Set.has(obj, name) ? "" : unknown(full),
|
||||
{
|
||||
test: function (obj) obj[name] != null && idx in obj[name]
|
||||
&& obj[name][idx] !== false
|
||||
&& (!flags.e || obj[name][idx] != "")
|
||||
}));
|
||||
}
|
||||
else {
|
||||
stack.top.elements.push(update(
|
||||
function (obj) obj[name] != null ? quote(obj[name]) : Set.has(obj, name) ? "" : unknown(full),
|
||||
{ test: function (obj) obj[name] != null && obj[name] !== false && (!flags.e || obj[name] != "") }));
|
||||
function (obj) obj[name] != null ? quote(obj[name])
|
||||
: Set.has(obj, name) ? "" : unknown(full),
|
||||
{
|
||||
test: function (obj) obj[name] != null
|
||||
&& obj[name] !== false
|
||||
&& (!flags.e || obj[name] != "")
|
||||
}));
|
||||
}
|
||||
|
||||
for (let elem in array.iterValues(stack))
|
||||
|
||||
Reference in New Issue
Block a user