mirror of
https://github.com/gryf/pentadactyl-pm.git
synced 2026-02-18 04:45:45 +01:00
[PWPBM] Make Personas work in private windows.
This commit is contained in:
@@ -8,9 +8,14 @@ try {
|
||||
|
||||
var global = this;
|
||||
defineModule("services", {
|
||||
exports: ["services"]
|
||||
exports: ["PrivateBrowsingUtils", "services"]
|
||||
});
|
||||
|
||||
try {
|
||||
var { PrivateBrowsingUtils } = Cu.import("resource://gre/modules/PrivateBrowsingUtils.jsm");
|
||||
}
|
||||
catch (e) {}
|
||||
|
||||
/**
|
||||
* A lazily-instantiated XPCOM class and service cache.
|
||||
*/
|
||||
|
||||
@@ -167,8 +167,7 @@ var sessionGlobal = Cu.import("resource://gre/modules/Services.jsm", {})
|
||||
var Storage = Module("Storage", {
|
||||
Local: function Local(dactyl, modules, window) ({
|
||||
init: function init() {
|
||||
this.privateMode = window.document.documentElement
|
||||
.getAttribute("privatebrowsingmode");
|
||||
this.privateMode = PrivateBrowsingUtils.isWindowPrivate(window);
|
||||
}
|
||||
}),
|
||||
|
||||
|
||||
Reference in New Issue
Block a user