1
0
mirror of https://github.com/gryf/pentadactyl-pm.git synced 2025-12-21 08:27:59 +01:00

Save option restore data until add-on is disabled. Cleanup preferences on uninstall.

This commit is contained in:
Kris Maglione
2011-07-29 05:29:06 -04:00
parent c165fd95be
commit a0de5d9e24
9 changed files with 180 additions and 130 deletions

6
common/bootstrap.js vendored
View File

@@ -241,11 +241,11 @@ function shutdown(data, reason) {
reportError(e);
}
if ([ADDON_UPGRADE, ADDON_DOWNGRADE, ADDON_UNINSTALL].indexOf(reason) >= 0)
if (~[ADDON_UPGRADE, ADDON_DOWNGRADE, ADDON_UNINSTALL].indexOf(reason))
Services.obs.notifyObservers(null, "dactyl-purge", null);
Services.obs.notifyObservers(null, "dactyl-cleanup", null);
Services.obs.notifyObservers(null, "dactyl-cleanup-modules", null);
Services.obs.notifyObservers(null, "dactyl-cleanup", reasonToString(reason));
Services.obs.notifyObservers(null, "dactyl-cleanup-modules", reasonToString(reason));
JSMLoader.purge();
for each (let [category, entry] in categories)