summaryrefslogtreecommitdiffstats
path: root/toolkit/profile/notifications.txt
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-07 19:33:14 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-07 19:33:14 +0000
commit36d22d82aa202bb199967e9512281e9a53db42c9 (patch)
tree105e8c98ddea1c1e4784a60a5a6410fa416be2de /toolkit/profile/notifications.txt
parentInitial commit. (diff)
downloadfirefox-esr-36d22d82aa202bb199967e9512281e9a53db42c9.tar.xz
firefox-esr-36d22d82aa202bb199967e9512281e9a53db42c9.zip
Adding upstream version 115.7.0esr.upstream/115.7.0esr
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'toolkit/profile/notifications.txt')
-rw-r--r--toolkit/profile/notifications.txt52
1 files changed, 52 insertions, 0 deletions
diff --git a/toolkit/profile/notifications.txt b/toolkit/profile/notifications.txt
new file mode 100644
index 0000000000..e6703b274c
--- /dev/null
+++ b/toolkit/profile/notifications.txt
@@ -0,0 +1,52 @@
+This Source Code Form is subject to the terms of the Mozilla Public
+License, v. 2.0. If a copy of the MPL was not distributed with this
+file, You can obtain one at http://mozilla.org/MPL/2.0/.
+
+nsIObserver topics for profile changing. Profile changing happens in phases
+in the order given below. An observer may register separately for each phase
+of the process depending on its needs.
+
+"profile-change-teardown"
+ All async activity must be stopped in this phase. Typically,
+ the application level observer will close all open windows.
+ This is the last phase in which the subject's vetoChange()
+ method may still be called.
+ The next notification will be either
+ profile-change-teardown-veto or profile-before-change.
+
+"profile-before-change"
+ Called before the profile has changed. Use this notification
+ to prepare for the profile going away. If a component is
+ holding any state which needs to be flushed to a profile-relative
+ location, it should be done here.
+
+"profile-do-change"
+ Called after the profile has changed. Do the work to
+ respond to having a new profile. Any change which
+ affects others must be done in this phase.
+
+"profile-after-change"
+ Called after the profile has changed. Use this notification
+ to make changes that are dependent on what some other listener
+ did during its profile-do-change. For example, to respond to
+ new preferences.
+
+"profile-initial-state"
+ Called after all phases of a change have completed. Typically
+ in this phase, an application level observer will open a new window.
+
+Contexts for profile changes. These are passed as the someData param to the
+observer's Observe() method.
+
+"startup"
+ Going from no profile to a profile.
+ The following topics happen in this context:
+ profile-do-change
+ profile-after-change
+
+See https://wiki.mozilla.org/XPCOM_Shutdown for more details about the shutdown
+process.
+
+NOTE: Long ago there was be a "shutdown-cleanse" version of shutdown which was
+intended to clear profile data. This is no longer sent and observer code should
+remove support for it.