The TabNotesController and TabNotes machinery currently assumes that `browser.tabs.notes.enabled` is either enabled or disabled during a user's entire session. This patch does a few things: 1. instead of just relying on the category manager to govern the life cycle for TabNotesController, that class also reacts to changes in the tab notes pref 2. since the TabNotesController depends on the CanonicalURL actor being ready after enabling the tab notes pref, the communication chain is pref -> DesktopActorRegistry -> TabNotesController instead of pref -> TabNotesController. 3. When turned on while the browser is running, we connect to TabNotes storage and ask all open tabs to parse for their canonical URLs. When turned off while the browser is running, we disconnect from TabNotes storage and clear all canonical URL/tab notes state on all tabs. Differential Revision: https://phabricator.services.mozilla.com/D279983
5 lines
591 B
Plaintext
5 lines
591 B
Plaintext
category browser-first-window-ready moz-src:///browser/components/tabnotes/TabNotesController.sys.mjs TabNotesController.browserFirstWindowReady
|
|
category browser-window-delayed-startup moz-src:///browser/components/tabnotes/TabNotesController.sys.mjs TabNotesController.browserWindowDelayedStartup
|
|
category browser-window-unload moz-src:///browser/components/tabnotes/TabNotesController.sys.mjs TabNotesController.browserWindowUnload
|
|
category browser-quit-application-granted moz-src:///browser/components/tabnotes/TabNotesController.sys.mjs TabNotesController.browserQuitApplicationGranted
|