1
0
mirror of https://github.com/gryf/pentadactyl-pm.git synced 2025-12-24 09:42:28 +01:00

Move the ACR disabler to common/, pass it an add-on ID.

--HG--
rename : pentadactyl/content/disable-acr.jsm => common/content/disable-acr.jsm
This commit is contained in:
Kris Maglione
2011-02-06 17:32:42 -05:00
parent 4d9c196b6c
commit a1f291a9ec
3 changed files with 17 additions and 16 deletions

12
common/bootstrap.js vendored
View File

@@ -169,9 +169,11 @@ function init() {
}
try {
module("resource://dactyl-local-content/disable-acr.jsm").init();
module("resource://dactyl-content/disable-acr.jsm").init(addon.id);
}
catch (e) {
reportError(e);
}
catch (e) {}
if (JSMLoader && JSMLoader.bump != 3) // Temporary hack
Services.scriptloader.loadSubScript("resource://dactyl" + suffix + "/bootstrap.jsm",
@@ -197,9 +199,11 @@ function shutdown(data, reason) {
dump("dactyl: bootstrap: shutdown " + reasonToString(reason) + "\n");
if (reason != APP_SHUTDOWN) {
try {
module("resource://dactyl-local-content/disable-acr.jsm").cleanup();
module("resource://dactyl-content/disable-acr.jsm").init(addon.id);
}
catch (e) {
reportError(e);
}
catch (e) {}
if ([ADDON_UPGRADE, ADDON_DOWNGRADE, ADDON_UNINSTALL].indexOf(reason) >= 0)
Services.obs.notifyObservers(null, "dactyl-purge", null);