Commit Graph

5 Commits

Author SHA1 Message Date
tophf
05c05ec6b9 manage: use chrome://favicon 2017-04-18 12:46:36 +03:00
tophf
2086f10af4 prefs.set: deep compare 2017-04-18 12:46:34 +03:00
tophf
8c539dabd6 prefs.set: enforce value type based on defaults 2017-04-18 12:46:34 +03:00
tophf
97c5972348 prefs: keep up-to-date using prefChanged event 2017-04-18 12:46:34 +03:00
tophf
5c8d1950a7 Isolate storage.js in background context
To prevent cross-page leaks we need to create/copy prefs and cachedStyles inside the background page context.

* storage.js is now used only in the background page

* messaging.js now contains less bg-specific methods and more common methods. Added saveStyleSafe, deleteStyleSafe which automatically invoke onRuntimeMessage of the current page or just handleUpdate/handleDelete when notify:false

* prefs.js with 'prefs' for background and UI pages: separate objects because a UI page may load before the background page and it can read prefs from localStorage/sync/defaults
2017-04-18 12:46:34 +03:00