From 09d9822ba85b99de75eadc756aa2c4d671861f6d Mon Sep 17 00:00:00 2001 From: Sandor Molnar Date: Thu, 14 Mar 2024 17:03:37 +0200 Subject: [PATCH] Backed out 3 changesets (bug 1884623) for causing multiple failures CLOSED TREE Backed out changeset 3a264233ce8e (bug 1884623) Backed out changeset acdf8a83a49c (bug 1884623) Backed out changeset de64ce832b8a (bug 1884623) --- dom/media/webvtt/WebVTTListener.cpp | 2 +- gfx/layers/apz/src/AutoscrollAnimation.cpp | 2 +- gfx/layers/apz/util/APZEventState.cpp | 2 +- intl/uconv/nsConverterInputStream.cpp | 2 +- js/src/gc/Statistics.cpp | 2 +- layout/forms/HTMLSelectEventListener.cpp | 2 +- modules/libpref/init/all.js | 2 +- netwerk/dns/nsEffectiveTLDService.cpp | 2 +- netwerk/docs/captive_portals.md | 2 +- netwerk/docs/dns/dns-over-https-trr.md | 2 +- netwerk/docs/url_parsers.md | 2 +- netwerk/protocol/http/nsHttpChannel.cpp | 3 +- netwerk/protocol/res/PageThumbProtocolHandler.cpp | 2 +- .../manager/ssl/RemoteSecuritySettings.sys.mjs | 2 +- .../scripts/periodic_file_updates.sh | 4 +- toolkit/actors/AutoCompleteParent.sys.mjs | 3 +- toolkit/actors/PictureInPictureChild.sys.mjs | 2 +- toolkit/actors/SelectChild.sys.mjs | 2 +- toolkit/actors/SelectParent.sys.mjs | 2 +- .../components/asyncshutdown/AsyncShutdown.sys.mjs | 3 +- .../cleardata/PrincipalsCollector.sys.mjs | 2 +- .../cleardata/ServiceWorkerCleanUp.sys.mjs | 2 +- .../components/cleardata/nsIClearDataService.idl | 2 +- .../ContextualIdentityService.sys.mjs | 2 +- toolkit/components/crashes/CrashManager.in.sys.mjs | 3 +- .../components/extensions/ConduitsChild.sys.mjs | 2 +- toolkit/components/extensions/Extension.sys.mjs | 2 +- .../components/extensions/ExtensionChild.sys.mjs | 8 +-- .../components/extensions/ExtensionCommon.sys.mjs | 6 +- .../components/extensions/ExtensionContent.sys.mjs | 2 +- toolkit/components/extensions/ExtensionDNR.sys.mjs | 2 +- .../extensions/ExtensionPageChild.sys.mjs | 2 +- .../components/extensions/ExtensionParent.sys.mjs | 10 +-- .../extensions/ExtensionProcessScript.sys.mjs | 2 +- .../extensions/ExtensionTestCommon.sys.mjs | 2 +- .../extensions/ProxyChannelFilter.sys.mjs | 4 +- toolkit/components/extensions/child/ext-storage.js | 2 +- toolkit/components/extensions/child/ext-test.js | 2 +- .../components/extensions/docs/webext-storage.rst | 2 +- .../components/extensions/docs/webidl_bindings.rst | 2 +- .../extensions/parent/ext-browsingData.js | 4 +- .../components/extensions/parent/ext-storage.js | 4 +- .../storage/webext_storage_bridge/src/lib.rs | 4 +- .../webidl-api/GenerateWebIDLBindings.py | 4 +- .../extensions/webrequest/WebRequest.sys.mjs | 2 +- .../formautofill/shared/FormAutofillUtils.sys.mjs | 2 +- toolkit/components/kvstore/kvstore.sys.mjs | 3 +- toolkit/components/kvstore/nsIKeyValue.idl | 4 +- .../components/messaging-system/schemas/index.rst | 4 +- toolkit/components/nimbus/FeatureManifest.yaml | 2 +- .../components/normandy/lib/AddonStudies.sys.mjs | 2 +- .../normandy/lib/PreferenceExperiments.sys.mjs | 2 +- .../passwordmgr/LoginAutoComplete.sys.mjs | 2 +- toolkit/components/passwordmgr/LoginHelper.sys.mjs | 2 +- .../components/passwordmgr/LoginManager.shared.mjs | 2 +- .../components/passwordmgr/LoginManager.sys.mjs | 2 +- .../passwordmgr/LoginManagerAuthPrompter.sys.mjs | 4 +- .../components/pictureinpicture/content/player.js | 6 +- toolkit/components/places/Bookmarks.sys.mjs | 81 ++++++++++------------ toolkit/components/places/History.sys.mjs | 27 +++----- toolkit/components/places/PlacesExpiration.sys.mjs | 4 +- toolkit/components/places/PlacesPreviews.sys.mjs | 8 +-- toolkit/components/places/PlacesSyncUtils.sys.mjs | 4 +- toolkit/components/places/Shutdown.h | 4 +- toolkit/components/places/mozIAsyncHistory.idl | 4 +- .../prompts/docs/nsIPromptService-reference.rst | 2 +- toolkit/components/prompts/src/Prompter.sys.mjs | 2 +- .../resistfingerprinting/RFPHelper.sys.mjs | 2 +- .../components/satchel/FormHistoryStartup.sys.mjs | 2 +- .../components/satchel/nsFormFillController.cpp | 2 +- .../components/taskscheduler/TaskScheduler.sys.mjs | 2 +- .../taskscheduler/TaskSchedulerMacOSImpl.sys.mjs | 2 +- .../taskscheduler/TaskSchedulerWinImpl.sys.mjs | 2 +- toolkit/components/telemetry/Histograms.json | 14 ++-- toolkit/components/telemetry/Scalars.yaml | 2 +- .../components/telemetry/TelemetryStartup.sys.mjs | 2 +- .../components/telemetry/docs/data/health-ping.rst | 2 +- .../telemetry/docs/obsolete/fhr/architecture.rst | 6 +- .../telemetry/docs/obsolete/fhr/dataformat.rst | 2 +- toolkit/components/translations/translations.d.ts | 2 +- .../UrlClassifierListManager.sys.mjs | 2 +- .../UrlClassifierRemoteSettingsService.sys.mjs | 2 +- .../url-classifier/nsIUrlListManager.idl | 2 +- toolkit/components/utils/ClientEnvironment.sys.mjs | 2 +- toolkit/content/aboutLogging.js | 2 +- toolkit/content/widgets/datetimebox.js | 2 +- toolkit/content/widgets/menu.js | 2 +- toolkit/content/widgets/textrecognition.js | 2 +- toolkit/content/widgets/videocontrols.js | 2 +- toolkit/crashreporter/docs/index.rst | 2 +- toolkit/modules/AppConstants.sys.mjs | 4 +- toolkit/modules/Console.sys.mjs | 2 +- toolkit/modules/docs/AsyncShutdown.rst | 8 +-- toolkit/modules/third_party/fathom/README | 2 +- toolkit/modules/third_party/fathom/fathom.mjs | 2 +- toolkit/mozapps/downloads/DownloadUtils.sys.mjs | 2 +- toolkit/mozapps/extensions/AddonManager.sys.mjs | 4 +- .../extensions/internal/AddonRepository.sys.mjs | 2 +- .../extensions/internal/AddonTestUtils.sys.mjs | 4 +- .../extensions/internal/AddonUpdateChecker.sys.mjs | 2 +- .../extensions/internal/XPIDatabase.sys.mjs | 2 +- .../mozapps/extensions/internal/XPIInstall.sys.mjs | 2 +- .../extensions/internal/XPIProvider.sys.mjs | 2 +- toolkit/mozapps/update/BackgroundUpdate.sys.mjs | 2 +- toolkit/mozapps/update/UpdateService.sys.mjs | 6 +- toolkit/mozapps/update/UpdateTelemetry.sys.mjs | 2 +- toolkit/mozapps/update/common/updatererrors.h | 18 ++--- toolkit/mozapps/update/docs/BackgroundUpdates.rst | 6 +- toolkit/mozapps/update/updater/updater.cpp | 17 ++--- toolkit/themes/shared/global-shared.css | 2 +- tools/profiler/core/platform.cpp | 2 +- uriloader/exthandler/nsExternalHelperAppService.h | 4 +- 112 files changed, 221 insertions(+), 235 deletions(-) diff --git a/dom/media/webvtt/WebVTTListener.cpp b/dom/media/webvtt/WebVTTListener.cpp index b0691491e35f..3f8d99a8f359 100644 --- a/dom/media/webvtt/WebVTTListener.cpp +++ b/dom/media/webvtt/WebVTTListener.cpp @@ -65,7 +65,7 @@ nsresult WebVTTListener::LoadResource() { if (IsCanceled()) { return NS_OK; } - // Exit if we failed to create the WebVTTParserWrapper (vtt.sys.mjs) + // Exit if we failed to create the WebVTTParserWrapper (vtt.jsm) NS_ENSURE_SUCCESS(mParserWrapperError, mParserWrapperError); mElement->SetReadyState(TextTrackReadyState::Loading); diff --git a/gfx/layers/apz/src/AutoscrollAnimation.cpp b/gfx/layers/apz/src/AutoscrollAnimation.cpp index 45063ef2b45b..8d4b8fca1017 100644 --- a/gfx/layers/apz/src/AutoscrollAnimation.cpp +++ b/gfx/layers/apz/src/AutoscrollAnimation.cpp @@ -17,7 +17,7 @@ namespace mozilla { namespace layers { // Helper function for AutoscrollAnimation::DoSample(). -// Basically copied as-is from toolkit/actors/AutoScrollChild.sys.mjs. +// Basically copied as-is from toolkit/actors/AutoScrollChild.jsm. static float Accelerate(ScreenCoord curr, ScreenCoord start) { static const int speed = 12; float val = (curr - start) / speed; diff --git a/gfx/layers/apz/util/APZEventState.cpp b/gfx/layers/apz/util/APZEventState.cpp index 5db6a0842980..7384296f4554 100644 --- a/gfx/layers/apz/util/APZEventState.cpp +++ b/gfx/layers/apz/util/APZEventState.cpp @@ -240,7 +240,7 @@ void APZEventState::ProcessLongTap(PresShell* aPresShell, false; #elif defined(MOZ_WIDGET_ANDROID) // On Android, GeckoView calls preventDefault() in a JSActor - // (ContentDelegateChild.sys.mjs) when opening context menu so that we can + // (ContentDelegateChild.jsm) when opening context menu so that we can // tell whether contextmenu opens in response to the contextmenu event by // checking where preventDefault() got called. preventDefaultResult == PreventDefaultResult::ByChrome; diff --git a/intl/uconv/nsConverterInputStream.cpp b/intl/uconv/nsConverterInputStream.cpp index 96fad345b29f..e3efdbc146c1 100644 --- a/intl/uconv/nsConverterInputStream.cpp +++ b/intl/uconv/nsConverterInputStream.cpp @@ -42,7 +42,7 @@ nsConverterInputStream::Init(nsIInputStream* aStream, const char* aCharset, aBufferSize = CONVERTER_BUFFER_SIZE; outputBufferSize = CONVERTER_BUFFER_SIZE; } else { - // NetUtil.sys.mjs assumes that if buffer size equals + // NetUtil.jsm assumes that if buffer size equals // the input size, the whole stream will be processed // as one readString. This is not true with encoding_rs, // because encoding_rs might want to see space for a diff --git a/js/src/gc/Statistics.cpp b/js/src/gc/Statistics.cpp index c12d44db976d..1cdd1b239197 100644 --- a/js/src/gc/Statistics.cpp +++ b/js/src/gc/Statistics.cpp @@ -595,7 +595,7 @@ UniqueChars Statistics::formatDetailedTotals() const { void Statistics::formatJsonSlice(size_t sliceNum, JSONPrinter& json) const { /* * We number each of the slice properties to keep the code in - * GCTelemetry.sys.mjs in sync. See MAX_SLICE_KEYS. + * GCTelemetry.jsm in sync. See MAX_SLICE_KEYS. */ json.beginObject(); formatJsonSliceDescription(sliceNum, slices_[sliceNum], json); // # 1-11 diff --git a/layout/forms/HTMLSelectEventListener.cpp b/layout/forms/HTMLSelectEventListener.cpp index 8c74c57cc009..4f6b1e356177 100644 --- a/layout/forms/HTMLSelectEventListener.cpp +++ b/layout/forms/HTMLSelectEventListener.cpp @@ -40,7 +40,7 @@ static bool IsOptionInteractivelySelectable(HTMLSelectElement& aSelect, // options in a display: contents subtree interactively. // test_select_key_navigation_bug1498769.html tests for this and should // probably be changed (and this loop removed) or alternatively - // SelectChild.sys.mjs should be changed to match it. + // SelectChild.jsm should be changed to match it. for (Element* el = &aOption; el && el != &aSelect; el = el->GetParentElement()) { if (Servo_Element_IsDisplayContents(el)) { diff --git a/modules/libpref/init/all.js b/modules/libpref/init/all.js index 7201f9ff22a1..f4dd972eb274 100644 --- a/modules/libpref/init/all.js +++ b/modules/libpref/init/all.js @@ -4016,7 +4016,7 @@ pref("toolkit.osKeyStore.loglevel", "Warn"); pref("extensions.formautofill.supportRTL", false); -// Controls the log level for CookieBannerListService.sys.mjs. +// Controls the log level for CookieBannerListService.jsm. pref("cookiebanners.listService.logLevel", "Error"); // Controls the log level for Cookie Banner Auto Clicking. diff --git a/netwerk/dns/nsEffectiveTLDService.cpp b/netwerk/dns/nsEffectiveTLDService.cpp index fc9e8c069209..fafbc296d5f3 100644 --- a/netwerk/dns/nsEffectiveTLDService.cpp +++ b/netwerk/dns/nsEffectiveTLDService.cpp @@ -74,7 +74,7 @@ NS_IMETHODIMP nsEffectiveTLDService::Observe(nsISupports* aSubject, const char* aTopic, const char16_t* aData) { /** - * Signal sent from netwerk/dns/PublicSuffixList.sys.mjs + * Signal sent from netwerk/dns/PublicSuffixList.jsm * aSubject is the nsIFile object for dafsa.bin * aData is the absolute path to the dafsa.bin file (not used) */ diff --git a/netwerk/docs/captive_portals.md b/netwerk/docs/captive_portals.md index 6606088b5427..fecba8f9136c 100644 --- a/netwerk/docs/captive_portals.md +++ b/netwerk/docs/captive_portals.md @@ -26,7 +26,7 @@ The [CaptivePortalService](https://searchfox.org/mozilla-central/source/netwerk/ - A captive portal was detected, and internet connectivity is not currently available. - A [captive portal notification bar](https://searchfox.org/mozilla-central/source/browser/base/content/browser-captivePortal.js) might be displayed to the user. -The Captive portal service uses [CaptiveDetect.sys.mjs](https://searchfox.org/mozilla-central/source/toolkit/components/captivedetect/CaptiveDetect.sys.mjs) to perform the checks, which in turn uses XMLHttpRequest. +The Captive portal service uses [CaptiveDetect.sys.mjs](https://searchfox.org/mozilla-central/source/toolkit/components/captivedetect/CaptiveDetect.jsm) to perform the checks, which in turn uses XMLHttpRequest. This request needs to be exempted from HTTPS upgrades, DNS over HTTPS, and many new browser features in order to function as expected. ```{note} diff --git a/netwerk/docs/dns/dns-over-https-trr.md b/netwerk/docs/dns/dns-over-https-trr.md index 7dfcff7dd726..cf025a1e6098 100644 --- a/netwerk/docs/dns/dns-over-https-trr.md +++ b/netwerk/docs/dns/dns-over-https-trr.md @@ -142,7 +142,7 @@ Some domains will never be resolved via TRR. This includes: A small set of TRR providers are only available on certain networks. -Detection is performed in DoHHeuristics.sys.mjs followed by a call to +Detection is performed in DoHHeuristics.jsm followed by a call to _TRRService::SetDetectedURI_. This causes Firefox to use the network specific TRR provider until a network change occurs. diff --git a/netwerk/docs/url_parsers.md b/netwerk/docs/url_parsers.md index 9fa25db1d965..a0b978a2b17e 100644 --- a/netwerk/docs/url_parsers.md +++ b/netwerk/docs/url_parsers.md @@ -67,7 +67,7 @@ To change a URI the consumer must call `nsIURI.mutate()` which returns a `nsIMut - [nsStandardURL](https://searchfox.org/mozilla-central/source/netwerk/base/nsStandardURL.h) - [SubstitutingURL](https://searchfox.org/mozilla-central/source/netwerk/protocol/res/SubstitutingURL.h) - overrides nsStandardURL::GetFile to provide nsIFile resolution. - - This allows us to map URLs such as `resource://gre/actors/RemotePageChild.sys.mjs` to the actual file on the disk. + - This allows us to map URLs such as `resource://gre/actors/RemotePageChild.jsm` to the actual file on the disk. - [nsMozIconURI](https://searchfox.org/mozilla-central/source/image/decoders/icon/nsIconURI.h) - Used to represent icon URLs - [nsSimpleURI](https://searchfox.org/mozilla-central/source/netwerk/base/nsSimpleURI.h) diff --git a/netwerk/protocol/http/nsHttpChannel.cpp b/netwerk/protocol/http/nsHttpChannel.cpp index 96e61e4fb8a2..af24b34ce688 100644 --- a/netwerk/protocol/http/nsHttpChannel.cpp +++ b/netwerk/protocol/http/nsHttpChannel.cpp @@ -547,8 +547,7 @@ nsresult nsHttpChannel::OnBeforeConnect() { } rv = sss->IsSecureURI(mURI, originAttributes, &isSecureURI); NS_ENSURE_SUCCESS(rv, rv); - // Save that on the loadInfo so it can later be consumed by - // SecurityInfo.sys.mjs + // Save that on the loadInfo so it can later be consumed by SecurityInfo.jsm mLoadInfo->SetHstsStatus(isSecureURI); RefPtr bc; diff --git a/netwerk/protocol/res/PageThumbProtocolHandler.cpp b/netwerk/protocol/res/PageThumbProtocolHandler.cpp index 2d9777da7b89..5918b40fadb3 100644 --- a/netwerk/protocol/res/PageThumbProtocolHandler.cpp +++ b/netwerk/protocol/res/PageThumbProtocolHandler.cpp @@ -207,7 +207,7 @@ bool PageThumbProtocolHandler::ResolveSpecialCases(const nsACString& aHost, const nsACString& aPath, const nsACString& aPathname, nsACString& aResult) { - // This should match the scheme in PageThumbs.sys.mjs. We will only resolve + // This should match the scheme in PageThumbs.jsm. We will only resolve // URIs for thumbnails generated by PageThumbs here. if (!aHost.EqualsLiteral(PAGE_THUMB_HOST) && !aHost.EqualsLiteral(PLACES_PREVIEWS_HOST)) { diff --git a/security/manager/ssl/RemoteSecuritySettings.sys.mjs b/security/manager/ssl/RemoteSecuritySettings.sys.mjs index 7781aff9c489..a9f974ed944d 100644 --- a/security/manager/ssl/RemoteSecuritySettings.sys.mjs +++ b/security/manager/ssl/RemoteSecuritySettings.sys.mjs @@ -29,7 +29,7 @@ ChromeUtils.defineLazyGetter(lazy, "log", () => { "resource://gre/modules/Console.sys.mjs" ); return new ConsoleAPI({ - prefix: "RemoteSecuritySettings", + prefix: "RemoteSecuritySettings.jsm", // tip: set maxLogLevel to "debug" and use log.debug() to create detailed // messages during development. See LOG_LEVELS in Console.sys.mjs for details. maxLogLevel: "error", diff --git a/taskcluster/docker/periodic-updates/scripts/periodic_file_updates.sh b/taskcluster/docker/periodic-updates/scripts/periodic_file_updates.sh index f01f5cd9c323..c5b9c78f6f82 100755 --- a/taskcluster/docker/periodic-updates/scripts/periodic_file_updates.sh +++ b/taskcluster/docker/periodic-updates/scripts/periodic_file_updates.sh @@ -322,7 +322,7 @@ function compare_remote_settings_files { # 5. Download attachments if needed. if [ "${bucket}" = "blocklists" ] && [ "${collection}" = "addons-bloomfilters" ]; then - # Find the attachment with the most recent generation_time, like _updateMLBF in Blocklist.sys.mjs. + # Find the attachment with the most recent generation_time, like _updateMLBF in Blocklist.jsm. # The server should return one "bloomfilter-base" record, but in case it returns multiple, # return the most recent one. The server may send multiple entries if we ever decide to use # the "filter_expression" feature of Remote Settings to send different records to specific @@ -364,7 +364,7 @@ function update_remote_settings_attachment() { # $4 is a jq filter on the arrays that should return one record with the attachment local jq_attachment_selector=".data | map(select(.attachment)) | $4" - # These paths match _readAttachmentDump in services/settings/Attachments.sys.mjs. + # These paths match _readAttachmentDump in services/settings/Attachments.jsm. local path_to_attachment="${bucket}/${collection}/${attachment_id}" local path_to_meta="${bucket}/${collection}/${attachment_id}.meta.json" local old_meta="$REMOTE_SETTINGS_INPUT/${path_to_meta}" diff --git a/toolkit/actors/AutoCompleteParent.sys.mjs b/toolkit/actors/AutoCompleteParent.sys.mjs index 611677a84f35..27f3dcbe075d 100644 --- a/toolkit/actors/AutoCompleteParent.sys.mjs +++ b/toolkit/actors/AutoCompleteParent.sys.mjs @@ -503,8 +503,7 @@ export class AutoCompleteParent extends JSWindowActorParent { * that the open popup should be focused. */ requestFocus() { - // Bug 1582722 - See the response in AutoCompleteChild.sys.mjs for why this - // disabled. + // Bug 1582722 - See the response in AutoCompleteChild.jsm for why this disabled. /* if (this.openedPopup) { this.sendAsyncMessage("FormAutoComplete:Focus"); diff --git a/toolkit/actors/PictureInPictureChild.sys.mjs b/toolkit/actors/PictureInPictureChild.sys.mjs index 2a415df32db6..b1ed71e2e8a1 100644 --- a/toolkit/actors/PictureInPictureChild.sys.mjs +++ b/toolkit/actors/PictureInPictureChild.sys.mjs @@ -1812,7 +1812,7 @@ export class PictureInPictureChild extends JSWindowActorChild { * 4) all active cues with VTTCue.line integer have VTTCue.snapToLines = true * 5) all active cues with VTTCue.line percentage have VTTCue.snapToLines = false * - * vtt.sys.mjs currently sets snapToLines to false if line is a percentage value, but + * vtt.jsm currently sets snapToLines to false if line is a percentage value, but * cues are still ordered by line. In most cases, snapToLines is set to true by default, * unless intentionally overridden. * @param allCuesArray {Array} array of active cues diff --git a/toolkit/actors/SelectChild.sys.mjs b/toolkit/actors/SelectChild.sys.mjs index 1bc80001ae13..2e3021733ec5 100644 --- a/toolkit/actors/SelectChild.sys.mjs +++ b/toolkit/actors/SelectChild.sys.mjs @@ -15,7 +15,7 @@ ChromeUtils.defineESModuleGetters(lazy, { const kStateActive = 0x00000001; // ElementState::ACTIVE const kStateHover = 0x00000004; // ElementState::HOVER -// Duplicated in SelectParent.sys.mjs +// Duplicated in SelectParent.jsm // Please keep these lists in sync. const SUPPORTED_OPTION_OPTGROUP_PROPERTIES = [ "direction", diff --git a/toolkit/actors/SelectParent.sys.mjs b/toolkit/actors/SelectParent.sys.mjs index 5382b35ab3a2..6d14807e448e 100644 --- a/toolkit/actors/SelectParent.sys.mjs +++ b/toolkit/actors/SelectParent.sys.mjs @@ -32,7 +32,7 @@ const PROPERTIES_RESET_WHEN_ACTIVE = [ "text-shadow", ]; -// Duplicated in SelectChild.sys.mjs +// Duplicated in SelectChild.jsm // Please keep these lists in sync. const SUPPORTED_OPTION_OPTGROUP_PROPERTIES = [ "direction", diff --git a/toolkit/components/asyncshutdown/AsyncShutdown.sys.mjs b/toolkit/components/asyncshutdown/AsyncShutdown.sys.mjs index 4577fa49a49c..4f0adc092a68 100644 --- a/toolkit/components/asyncshutdown/AsyncShutdown.sys.mjs +++ b/toolkit/components/asyncshutdown/AsyncShutdown.sys.mjs @@ -335,7 +335,8 @@ function getOrigin(topFrame, filename = null, lineNumber = null, stack = null) { lineNumber = frame ? frame.lineNumber : 0; } if (stack == null) { - // Now build the rest of the stack as a string. + // Now build the rest of the stack as a string, using Task.jsm's rewriting + // to ensure that we do not lose information at each call to `Task.spawn`. stack = []; while (frame != null) { stack.push(frame.filename + ":" + frame.name + ":" + frame.lineNumber); diff --git a/toolkit/components/cleardata/PrincipalsCollector.sys.mjs b/toolkit/components/cleardata/PrincipalsCollector.sys.mjs index e4f5e827f62e..2b5917c6ce44 100644 --- a/toolkit/components/cleardata/PrincipalsCollector.sys.mjs +++ b/toolkit/components/cleardata/PrincipalsCollector.sys.mjs @@ -17,7 +17,7 @@ let logConsole; function log(msg) { if (!logConsole) { logConsole = console.createInstance({ - prefix: "PrincipalsCollector", + prefix: "** PrincipalsCollector.jsm", maxLogLevelPref: "browser.sanitizer.loglevel", }); } diff --git a/toolkit/components/cleardata/ServiceWorkerCleanUp.sys.mjs b/toolkit/components/cleardata/ServiceWorkerCleanUp.sys.mjs index b513e47aba55..1c49b2be08b9 100644 --- a/toolkit/components/cleardata/ServiceWorkerCleanUp.sys.mjs +++ b/toolkit/components/cleardata/ServiceWorkerCleanUp.sys.mjs @@ -15,7 +15,7 @@ XPCOMUtils.defineLazyServiceGetter( if (Services.appinfo.processType === Services.appinfo.PROCESS_TYPE_CONTENT) { throw new Error( - "ServiceWorkerCleanUp.sys.mjs can only be used in the parent process" + "ServiceWorkerCleanUp.jsm can only be used in the parent process" ); } diff --git a/toolkit/components/cleardata/nsIClearDataService.idl b/toolkit/components/cleardata/nsIClearDataService.idl index ea17059bbeb3..0dff281dbe63 100644 --- a/toolkit/components/cleardata/nsIClearDataService.idl +++ b/toolkit/components/cleardata/nsIClearDataService.idl @@ -140,7 +140,7 @@ interface nsIClearDataService : nsISupports * whose base domain does not have any storage associated with it. * * The principals to be considered will need to be passed by the API consumer. - * It is recommended to use PrincipalsCollector.sys.mjs for that. + * It is recommended to use PrincipalsCollector.jsm for that. * * @param aPrincipalsWithStorage principals to be excluded from clearing * @param aFrom microseconds from the epoch diff --git a/toolkit/components/contextualidentity/ContextualIdentityService.sys.mjs b/toolkit/components/contextualidentity/ContextualIdentityService.sys.mjs index 738f8743eea3..fefe162ea0b1 100644 --- a/toolkit/components/contextualidentity/ContextualIdentityService.sys.mjs +++ b/toolkit/components/contextualidentity/ContextualIdentityService.sys.mjs @@ -90,7 +90,7 @@ _ContextualIdentityService.prototype = { name: "userContextIdInternal.thumbnail", accessKey: "", }, - // This userContextId is used by ExtensionStorageIDB.sys.mjs to create an IndexedDB database + // This userContextId is used by ExtensionStorageIDB.jsm to create an IndexedDB database // opened with the extension principal but not directly accessible to the extension code // (do not change the userContextId assigned here, otherwise the installed extensions will // not be able to access the data previously stored with the browser.storage.local API). diff --git a/toolkit/components/crashes/CrashManager.in.sys.mjs b/toolkit/components/crashes/CrashManager.in.sys.mjs index 9e89c81d91dc..253f70d07edf 100644 --- a/toolkit/components/crashes/CrashManager.in.sys.mjs +++ b/toolkit/components/crashes/CrashManager.in.sys.mjs @@ -24,7 +24,8 @@ const AGGREGATE_STARTUP_DELAY_MS = 57000; const MILLISECONDS_IN_DAY = 24 * 60 * 60 * 1000; // Converts Date to days since UNIX epoch. -// The implementation does not account for leap seconds. +// This was copied from /services/metrics.storage.jsm. The implementation +// does not account for leap seconds. export function dateToDays(date) { return Math.floor(date.getTime() / MILLISECONDS_IN_DAY); } diff --git a/toolkit/components/extensions/ConduitsChild.sys.mjs b/toolkit/components/extensions/ConduitsChild.sys.mjs index 598804f74a2a..c5774ab39c67 100644 --- a/toolkit/components/extensions/ConduitsChild.sys.mjs +++ b/toolkit/components/extensions/ConduitsChild.sys.mjs @@ -4,7 +4,7 @@ /** * This @file implements the child side of Conduits, an abstraction over - * Fission IPC for extension API subject. See {@link ConduitsParent.sys.mjs} + * Fission IPC for extension API subject. See {@link ConduitsParent.jsm} * for more details about the overall design. * * @typedef {object} MessageData diff --git a/toolkit/components/extensions/Extension.sys.mjs b/toolkit/components/extensions/Extension.sys.mjs index de6d4c8bfd51..e8e8b27ad264 100644 --- a/toolkit/components/extensions/Extension.sys.mjs +++ b/toolkit/components/extensions/Extension.sys.mjs @@ -3205,7 +3205,7 @@ export class Extension extends ExtensionData { // Extended serialized data which is only needed in the extensions process, // and is never deserialized in web content processes. - // Keep in sync with BrowserExtensionContent in ExtensionChild.sys.mjs + // Keep in sync with BrowserExtensionContent in ExtensionChild.jsm serializeExtended() { return { backgroundScripts: this.backgroundScripts, diff --git a/toolkit/components/extensions/ExtensionChild.sys.mjs b/toolkit/components/extensions/ExtensionChild.sys.mjs index 70774db3957c..63c1bedec1f2 100644 --- a/toolkit/components/extensions/ExtensionChild.sys.mjs +++ b/toolkit/components/extensions/ExtensionChild.sys.mjs @@ -8,7 +8,7 @@ * This file handles addon logic that is independent of the chrome process and * may run in all web content and extension processes. * - * Don't put contentscript logic here, use ExtensionContent.sys.mjs instead. + * Don't put contentscript logic here, use ExtensionContent.jsm instead. */ import { XPCOMUtils } from "resource://gre/modules/XPCOMUtils.sys.mjs"; @@ -397,7 +397,7 @@ class BrowserExtensionContent extends EventEmitter { this.optionalPermissions = policy.optionalPermissions; if (WebExtensionPolicy.isExtensionProcess) { - // Keep in sync with serializeExtended in Extension.sys.mjs + // Keep in sync with serializeExtended in Extension.jsm let ed = this.getSharedData("extendedData"); this.backgroundScripts = ed.backgroundScripts; this.backgroundWorkerScript = ed.backgroundWorkerScript; @@ -727,8 +727,8 @@ class ChildLocalAPIImplementation extends LocalAPIImplementation { // We create one instance of this class for every extension context that // needs to use remote APIs. It uses the the JSWindowActor and -// JSProcessActor Conduits actors (see ConduitsChild.sys.mjs) to communicate -// with the ParentAPIManager singleton in ExtensionParent.sys.mjs. +// JSProcessActor Conduits actors (see ConduitsChild.jsm) to communicate +// with the ParentAPIManager singleton in ExtensionParent.jsm. // It handles asynchronous function calls as well as event listeners. class ChildAPIManager { constructor(context, messageManager, localAPICan, contextData) { diff --git a/toolkit/components/extensions/ExtensionCommon.sys.mjs b/toolkit/components/extensions/ExtensionCommon.sys.mjs index 512d1444a526..1460f4d2018b 100644 --- a/toolkit/components/extensions/ExtensionCommon.sys.mjs +++ b/toolkit/components/extensions/ExtensionCommon.sys.mjs @@ -7,7 +7,7 @@ /** * This module contains utilities and base classes for logic which is * common between the parent and child process, and in particular - * between ExtensionParent.sys.mjs and ExtensionChild.sys.mjs. + * between ExtensionParent.jsm and ExtensionChild.jsm. */ import { XPCOMUtils } from "resource://gre/modules/XPCOMUtils.sys.mjs"; @@ -1033,7 +1033,7 @@ class BaseContext { /** * An object that runs the implementation of a schema API. Instantiations of - * this interfaces are used by Schemas.sys.mjs. + * this interfaces are used by Schemas.jsm. * * @interface */ @@ -1865,7 +1865,7 @@ class SchemaAPIManager extends EventEmitter { { wantXrays: false, wantGlobalProperties: ["ChromeUtils"], - sandboxName: `Namespace of ext-*.js scripts for ${this.processType} (from: resource://gre/modules/ExtensionCommon.sys.mjs)`, + sandboxName: `Namespace of ext-*.js scripts for ${this.processType} (from: resource://gre/modules/ExtensionCommon.jsm)`, } ); diff --git a/toolkit/components/extensions/ExtensionContent.sys.mjs b/toolkit/components/extensions/ExtensionContent.sys.mjs index 015d1bc7c691..af086e732a10 100644 --- a/toolkit/components/extensions/ExtensionContent.sys.mjs +++ b/toolkit/components/extensions/ExtensionContent.sys.mjs @@ -787,7 +787,7 @@ var contentScripts = new DefaultWeakMap(matcher => { * An execution context for semi-privileged extension content scripts. * * This is the child side of the ContentScriptContextParent class - * defined in ExtensionParent.sys.mjs. + * defined in ExtensionParent.jsm. */ class ContentScriptContextChild extends BaseContext { constructor(extension, contentWindow) { diff --git a/toolkit/components/extensions/ExtensionDNR.sys.mjs b/toolkit/components/extensions/ExtensionDNR.sys.mjs index d18856a2b818..b23eea140da0 100644 --- a/toolkit/components/extensions/ExtensionDNR.sys.mjs +++ b/toolkit/components/extensions/ExtensionDNR.sys.mjs @@ -1913,7 +1913,7 @@ const NetworkIntegration = { maxEvaluatedRulesCount: 0, register() { - // We register via WebRequest.sys.mjs to ensure predictable ordering of DNR and + // We register via WebRequest.jsm to ensure predictable ordering of DNR and // WebRequest behavior. lazy.WebRequest.setDNRHandlingEnabled(true); }, diff --git a/toolkit/components/extensions/ExtensionPageChild.sys.mjs b/toolkit/components/extensions/ExtensionPageChild.sys.mjs index 17c208572b21..7914268b708e 100644 --- a/toolkit/components/extensions/ExtensionPageChild.sys.mjs +++ b/toolkit/components/extensions/ExtensionPageChild.sys.mjs @@ -299,7 +299,7 @@ class ExtensionPageContextChild extends ExtensionBaseContextChild { * APIs (provided that the correct permissions have been requested). * * This is the child side of the ExtensionPageContextParent class - * defined in ExtensionParent.sys.mjs. + * defined in ExtensionParent.jsm. * * @param {BrowserExtensionContent} extension This context's owner. * @param {object} params diff --git a/toolkit/components/extensions/ExtensionParent.sys.mjs b/toolkit/components/extensions/ExtensionParent.sys.mjs index b4812a702a2a..6f31341875a1 100644 --- a/toolkit/components/extensions/ExtensionParent.sys.mjs +++ b/toolkit/components/extensions/ExtensionParent.sys.mjs @@ -7,7 +7,7 @@ /** * This module contains code for managing APIs that need to run in the * parent process, and handles the parent side of operations that need - * to be proxied from ExtensionChild.sys.mjs. + * to be proxied from ExtensionChild.jsm. */ import { XPCOMUtils } from "resource://gre/modules/XPCOMUtils.sys.mjs"; @@ -481,7 +481,7 @@ GlobalManager = { }; /** - * The proxied parent side of a context in ExtensionChild.sys.mjs, for the + * The proxied parent side of a context in ExtensionChild.jsm, for the * parent side of a proxied API. */ class ProxyContextParent extends BaseContext { @@ -685,14 +685,14 @@ class ProxyContextParent extends BaseContext { /** * The parent side of proxied API context for extension content script - * running in ExtensionContent.sys.mjs. + * running in ExtensionContent.jsm. */ class ContentScriptContextParent extends ProxyContextParent {} /** * The parent side of proxied API context for extension page, such as a * background script, a tab page, or a popup, running in - * ExtensionChild.sys.mjs. + * ExtensionChild.jsm. */ class ExtensionPageContextParent extends ProxyContextParent { constructor(envType, extension, params, browsingContext) { @@ -741,7 +741,7 @@ class ExtensionPageContextParent extends ProxyContextParent { /** * The parent side of proxied API context for devtools extension page, such as a - * devtools pages and panels running in ExtensionChild.sys.mjs. + * devtools pages and panels running in ExtensionChild.jsm. */ class DevToolsExtensionPageContextParent extends ExtensionPageContextParent { constructor(...params) { diff --git a/toolkit/components/extensions/ExtensionProcessScript.sys.mjs b/toolkit/components/extensions/ExtensionProcessScript.sys.mjs index 93746cb0caf8..5032542d12b0 100644 --- a/toolkit/components/extensions/ExtensionProcessScript.sys.mjs +++ b/toolkit/components/extensions/ExtensionProcessScript.sys.mjs @@ -325,7 +325,7 @@ ExtensionManager = { if (!policy) { break; } - // In the parent process, Extension.sys.mjs updates the policy. + // In the parent process, Extension.jsm updates the policy. if (lazy.isContentProcess) { lazy.ExtensionCommon.updateAllowedOrigins( policy, diff --git a/toolkit/components/extensions/ExtensionTestCommon.sys.mjs b/toolkit/components/extensions/ExtensionTestCommon.sys.mjs index 701a85d97bbf..94cb801cc5ed 100644 --- a/toolkit/components/extensions/ExtensionTestCommon.sys.mjs +++ b/toolkit/components/extensions/ExtensionTestCommon.sys.mjs @@ -100,7 +100,7 @@ export class MockExtension { this._extensionPromise.then(extension => { extension.on(...args); }); - // Extension.sys.mjs emits a "startup" event on |extension| before emitting the + // Extension.jsm emits a "startup" event on |extension| before emitting the // "startup" event on |apiManager|. Trigger the "startup" event anyway, to // make sure that the MockExtension behaves like an Extension with regards // to the startup event. diff --git a/toolkit/components/extensions/ProxyChannelFilter.sys.mjs b/toolkit/components/extensions/ProxyChannelFilter.sys.mjs index 444602f2fa76..f33bd04b0349 100644 --- a/toolkit/components/extensions/ProxyChannelFilter.sys.mjs +++ b/toolkit/components/extensions/ProxyChannelFilter.sys.mjs @@ -286,8 +286,8 @@ export class ProxyChannelFilter { ); } - // Originally duplicated from WebRequest.sys.mjs with small changes. Keep this - // in sync with WebRequest.sys.mjs as well as parent/ext-webRequest.js when + // Originally duplicated from WebRequest.jsm with small changes. Keep this + // in sync with WebRequest.jsm as well as parent/ext-webRequest.js when // apropiate. getRequestData(channel, extraData) { let originAttributes = channel.loadInfo?.originAttributes; diff --git a/toolkit/components/extensions/child/ext-storage.js b/toolkit/components/extensions/child/ext-storage.js index 3d71a1cd60eb..4c1afff070b7 100644 --- a/toolkit/components/extensions/child/ext-storage.js +++ b/toolkit/components/extensions/child/ext-storage.js @@ -185,7 +185,7 @@ this.storage = class extends ExtensionAPI { return items; } // If we got here, then `items` is an object generated by `ObjectType`'s - // `normalize` method from Schemas.sys.mjs. The object returned by `normalize` + // `normalize` method from Schemas.jsm. The object returned by `normalize` // lives in this compartment, while the values live in compartment of // `context.contentWindow`. The `sanitize` method runs with the principal // of `context`, so we cannot just use `ExtensionStorage.sanitize` because diff --git a/toolkit/components/extensions/child/ext-test.js b/toolkit/components/extensions/child/ext-test.js index 3d9835d61f75..f85845168d0e 100644 --- a/toolkit/components/extensions/child/ext-test.js +++ b/toolkit/components/extensions/child/ext-test.js @@ -248,7 +248,7 @@ this.test = class extends ExtensionAPI { }, assertDeepEq(expected, actual, msg) { - // The bindings generated by Schemas.sys.mjs accepts any input, but the + // The bindings generated by Schemas.jsm accepts any input, but the // WebIDL-generated binding expects a structurally cloneable input. // To ensure consistent behavior regardless of which mechanism was // used, verify that the inputs are structurally cloneable. diff --git a/toolkit/components/extensions/docs/webext-storage.rst b/toolkit/components/extensions/docs/webext-storage.rst index 27ba3ad4d76a..9b5f2428d686 100644 --- a/toolkit/components/extensions/docs/webext-storage.rst +++ b/toolkit/components/extensions/docs/webext-storage.rst @@ -207,7 +207,7 @@ the actual result of the function (also a set of changes to send to observers, b beyond this doc). Ultimately, the `PuntResult` ends up back on the main thread once the call is complete -and arranges to callback the JS implementation, which in turn resolves the promise created in `ExtensionStorageSync.sys.mjs` +and arranges to callback the JS implementation, which in turn resolves the promise created in `ExtensionStorageSync.jsm` End result: ----------- diff --git a/toolkit/components/extensions/docs/webidl_bindings.rst b/toolkit/components/extensions/docs/webidl_bindings.rst index 7f7f2e53cbf2..be8c63d0a773 100644 --- a/toolkit/components/extensions/docs/webidl_bindings.rst +++ b/toolkit/components/extensions/docs/webidl_bindings.rst @@ -4,7 +4,7 @@ WebIDL WebExtensions API Bindings While on ``manifest_version: 2`` all the extension globals (extension pages and content scripts) that lives on the main thread and the WebExtensions API bindings can be injected into the extension global from the JS privileged code part of the WebExtensions internals (`See Schemas.inject defined in -Schemas.sys.mjs `_), +Schemas.jsm `_), in ``manifest_version: 3`` the extension will be able to declare a background service worker instead of a background page, and the existing WebExtensions API bindings can't be injected into this new extension global, because it lives off of the main thread. diff --git a/toolkit/components/extensions/parent/ext-browsingData.js b/toolkit/components/extensions/parent/ext-browsingData.js index 6d4b721e4f11..d06f7a3a1ba8 100644 --- a/toolkit/components/extensions/parent/ext-browsingData.js +++ b/toolkit/components/extensions/parent/ext-browsingData.js @@ -80,7 +80,7 @@ const clearCache = options => { const clearCookies = async function (options) { let cookieMgr = Services.cookies; - // This code has been borrowed from Sanitizer.sys.mjs. + // This code has been borrowed from Sanitizer.jsm. let yieldCounter = 0; if (options.since || options.hostnames || options.cookieStoreId) { @@ -126,7 +126,7 @@ const clearCookies = async function (options) { } }; -// Ideally we could reuse the logic in Sanitizer.sys.mjs or nsIClearDataService, +// Ideally we could reuse the logic in Sanitizer.jsm or nsIClearDataService, // but this API exposes an ability to wipe data at a much finger granularity // than those APIs. (See also Bug 1531276) async function clearQuotaManager(options, dataType) { diff --git a/toolkit/components/extensions/parent/ext-storage.js b/toolkit/components/extensions/parent/ext-storage.js index b4ee9ab42254..350ca0acfa23 100644 --- a/toolkit/components/extensions/parent/ext-storage.js +++ b/toolkit/components/extensions/parent/ext-storage.js @@ -192,8 +192,8 @@ this.storage = class extends ExtensionAPIPersistent { extension, onStorageSyncChanged ); - // May be void if ExtensionStorageSyncKinto.sys.mjs was not used. - // ExtensionStorageSync.sys.mjs does not use the context. + // May be void if ExtensionStorageSyncKinto.jsm was not used. + // ExtensionStorageSync.jsm does not use the context. closeCallback?.(); }; } diff --git a/toolkit/components/extensions/storage/webext_storage_bridge/src/lib.rs b/toolkit/components/extensions/storage/webext_storage_bridge/src/lib.rs index c1998fb6367f..94133ef1e996 100644 --- a/toolkit/components/extensions/storage/webext_storage_bridge/src/lib.rs +++ b/toolkit/components/extensions/storage/webext_storage_bridge/src/lib.rs @@ -16,11 +16,11 @@ //! and `storage.managed`, which is provisioned in a native manifest and //! read-only. //! -//! * `storage.local` is implemented in `ExtensionStorageIDB.sys.mjs`. +//! * `storage.local` is implemented in `ExtensionStorageIDB.jsm`. //! * `storage.sync` is implemented in a Rust component, `webext_storage`. This //! Rust component is vendored in m-c, and exposed to JavaScript via an XPCOM //! API in `webext_storage_bridge` (this crate). Eventually, we'll change -//! `ExtensionStorageSync.sys.mjs` to call the XPCOM API instead of using the +//! `ExtensionStorageSync.jsm` to call the XPCOM API instead of using the //! old Kinto storage adapter. //! * `storage.managed` is implemented directly in `parent/ext-storage.js`. //! diff --git a/toolkit/components/extensions/webidl-api/GenerateWebIDLBindings.py b/toolkit/components/extensions/webidl-api/GenerateWebIDLBindings.py index 6a4a404ac848..3b31bd924da0 100644 --- a/toolkit/components/extensions/webidl-api/GenerateWebIDLBindings.py +++ b/toolkit/components/extensions/webidl-api/GenerateWebIDLBindings.py @@ -139,8 +139,8 @@ def read_json(json_file_path): """ Helper function used to read the WebExtensions API schema JSON files by ignoring the license comment on the top of some of those files. - Same helper as the one available in Schemas.sys.mjs: - https://searchfox.org/mozilla-central/rev/b60cb73160843adb5a5a3ec8058e75a69b46acf7/toolkit/components/extensions/Schemas.sys.mjs#53 + Same helper as the one available in Schemas.jsm: + https://searchfox.org/mozilla-central/rev/3434a9df60373a997263107e6f124fb164ddebf2/toolkit/components/extensions/Schemas.jsm#70 """ with open(json_file_path) as json_file: txt = json_file.read() diff --git a/toolkit/components/extensions/webrequest/WebRequest.sys.mjs b/toolkit/components/extensions/webrequest/WebRequest.sys.mjs index bbe044ddeaa2..b9c50972143d 100644 --- a/toolkit/components/extensions/webrequest/WebRequest.sys.mjs +++ b/toolkit/components/extensions/webrequest/WebRequest.sys.mjs @@ -15,7 +15,7 @@ ChromeUtils.defineESModuleGetters(lazy, { WebRequestUpload: "resource://gre/modules/WebRequestUpload.sys.mjs", }); -// WebRequest.sys.mjs's only consumer is ext-webRequest.js, so we can depend on +// WebRequest.jsm's only consumer is ext-webRequest.js, so we can depend on // the apiManager.global being initialized. ChromeUtils.defineLazyGetter(lazy, "tabTracker", () => { return lazy.ExtensionParent.apiManager.global.tabTracker; diff --git a/toolkit/components/formautofill/shared/FormAutofillUtils.sys.mjs b/toolkit/components/formautofill/shared/FormAutofillUtils.sys.mjs index e86f14975c7a..c9e570bf4a33 100644 --- a/toolkit/components/formautofill/shared/FormAutofillUtils.sys.mjs +++ b/toolkit/components/formautofill/shared/FormAutofillUtils.sys.mjs @@ -192,7 +192,7 @@ FormAutofillUtils = { getAddressLabel(address) { // TODO: Implement a smarter way for deciding what to display // as option text. Possibly improve the algorithm in - // ProfileAutoCompleteResult.sys.mjs and reuse it here. + // ProfileAutoCompleteResult.jsm and reuse it here. let fieldOrder = [ "name", "-moz-street-address-one-line", // Street address diff --git a/toolkit/components/kvstore/kvstore.sys.mjs b/toolkit/components/kvstore/kvstore.sys.mjs index 9085eed530c5..f320ca6cc5e3 100644 --- a/toolkit/components/kvstore/kvstore.sys.mjs +++ b/toolkit/components/kvstore/kvstore.sys.mjs @@ -18,8 +18,7 @@ function promisify(fn, ...args) { * with a database's path and (optionally) its name: * * ``` - * let { keyValueService } = - * ChromeUtils.importESModule("resource://gre/modules/kvstore.sys.mjs"); + * ChromeUtils.import("resource://gre/modules/kvstore.jsm"); * let database = await KeyValueService.getOrCreate(path, name); * ``` * diff --git a/toolkit/components/kvstore/nsIKeyValue.idl b/toolkit/components/kvstore/nsIKeyValue.idl index 08cd548af25c..a9450fd638e6 100644 --- a/toolkit/components/kvstore/nsIKeyValue.idl +++ b/toolkit/components/kvstore/nsIKeyValue.idl @@ -22,7 +22,7 @@ interface nsIKeyValuePair; * for all use cases. Extension of this API to support transactions is tracked * by bug 1499238. * - * The kvstore.sys.mjs module wraps this API in a more idiomatic, Promise-based + * The kvstore.jsm module wraps this API in a more idiomatic, Promise-based * JS API that supports async/await. In most cases, you're better off using * that API from JS rather than using this one directly. Bug 1512319 tracks * native support for Promise in Rust-implemented XPCOM methods. @@ -169,7 +169,7 @@ interface nsIKeyValuePair : nsISupports { * an nsIKeyValuePair rather than an nsISupports, so consumers don't need * to QI it to that interface; but this interface doesn't implement the JS * iteration protocol (because the Rust-XPCOM bindings don't yet support it), - * which is another reason why you should use the kvstore.sys.mjs module from JS + * which is another reason why you should use the kvstore.jsm module from JS * instead of accessing this API directly. */ [scriptable, builtinclass, rust_sync, uuid(b9ba7116-b7ff-4717-9a28-a08e6879b199)] diff --git a/toolkit/components/messaging-system/schemas/index.rst b/toolkit/components/messaging-system/schemas/index.rst index 957dd06c3aa2..f4db543600f1 100644 --- a/toolkit/components/messaging-system/schemas/index.rst +++ b/toolkit/components/messaging-system/schemas/index.rst @@ -178,8 +178,8 @@ Triggers and actions .. _Experimenter: https://experimenter.info -.. _CFRMessageProvider: https://searchfox.org/mozilla-central/source/browser/components/asrouter/modules/CFRMessageProvider.sys.mjs -.. _PanelTestProvider: https://searchfox.org/mozilla-central/source/browser/components/asrouter/modules/PanelTestProvider.sys.mjs +.. _CFRMessageProvider: https://searchfox.org/mozilla-central/source/browser/components/asrouter/modules/CFRMessageProvider.jsm +.. _PanelTestProvider: https://searchfox.org/mozilla-central/source/browser/components/asrouter/modules/PanelTestProvider.jsm .. _OnboardingMessageProvider: https://searchfox.org/mozilla-central/source/browser/components/asrouter/modules/OnboardingMessageProvider.sys.mjs .. _Test_CFRMessageProvider: https://searchfox.org/mozilla-central/source/browser/components/asrouter/tests//xpcshell/test_CFMessageProvider.js .. _Test_OnboardingMessageProvider: https://searchfox.org/mozilla-central/source/browser/components/asrouter/tests//xpcshell/test_OnboardingMessageProvider.js diff --git a/toolkit/components/nimbus/FeatureManifest.yaml b/toolkit/components/nimbus/FeatureManifest.yaml index 40421e7a7762..4a43fc319be8 100644 --- a/toolkit/components/nimbus/FeatureManifest.yaml +++ b/toolkit/components/nimbus/FeatureManifest.yaml @@ -316,7 +316,7 @@ urlbar: Whether Firefox Suggest will use the new Rust backend instead of the original JS backend. quickSuggestScenario: - # IMPORTANT: This should not have a fallbackPref. See UrlbarPrefs.sys.mjs. + # IMPORTANT: This should not have a fallbackPref. See UrlbarPrefs.jsm. type: string description: The Firefox Suggest scenario in which the user is enrolled enum: diff --git a/toolkit/components/normandy/lib/AddonStudies.sys.mjs b/toolkit/components/normandy/lib/AddonStudies.sys.mjs index e13d470bd7da..202bf8ccb3bd 100644 --- a/toolkit/components/normandy/lib/AddonStudies.sys.mjs +++ b/toolkit/components/normandy/lib/AddonStudies.sys.mjs @@ -162,7 +162,7 @@ export var AddonStudies = { }, /** - * These migrations should only be called from `NormandyMigrations.sys.mjs` and + * These migrations should only be called from `NormandyMigrations.jsm` and * tests. */ migrations: { diff --git a/toolkit/components/normandy/lib/PreferenceExperiments.sys.mjs b/toolkit/components/normandy/lib/PreferenceExperiments.sys.mjs index 92c5e63076b9..d926f5221dda 100644 --- a/toolkit/components/normandy/lib/PreferenceExperiments.sys.mjs +++ b/toolkit/components/normandy/lib/PreferenceExperiments.sys.mjs @@ -906,7 +906,7 @@ export var PreferenceExperiments = { InvalidPreferenceName: class extends Error {}, /** - * These migrations should only be called from `NormandyMigrations.sys.mjs` and tests. + * These migrations should only be called from `NormandyMigrations.jsm` and tests. */ migrations: { /** Move experiments into a specific key. */ diff --git a/toolkit/components/passwordmgr/LoginAutoComplete.sys.mjs b/toolkit/components/passwordmgr/LoginAutoComplete.sys.mjs index 411d9249dbf1..6ff96d999e5f 100644 --- a/toolkit/components/passwordmgr/LoginAutoComplete.sys.mjs +++ b/toolkit/components/passwordmgr/LoginAutoComplete.sys.mjs @@ -503,7 +503,7 @@ export class LoginAutoComplete { let searchStartTimeMS = Services.telemetry.msSystemNow(); // Show the insecure login warning in the passwords field on null principal documents. - // Avoid loading InsecurePasswordUtils.sys.mjs in a sandboxed document (e.g. an ad. frame) if we + // Avoid loading InsecurePasswordUtils.jsm in a sandboxed document (e.g. an ad. frame) if we // already know it has a null principal and will therefore get the insecure autocomplete // treatment. // InsecurePasswordUtils doesn't handle the null principal case as not secure because we don't diff --git a/toolkit/components/passwordmgr/LoginHelper.sys.mjs b/toolkit/components/passwordmgr/LoginHelper.sys.mjs index 5626312f179b..a63654c8f205 100644 --- a/toolkit/components/passwordmgr/LoginHelper.sys.mjs +++ b/toolkit/components/passwordmgr/LoginHelper.sys.mjs @@ -1371,7 +1371,7 @@ export const LoginHelper = { * @returns {boolean} True if any of the rules matches */ isInferredLoginForm(formElement) { - // This is copied from 'loginFormAttrRegex' in NewPasswordModel.sys.mjs + // This is copied from 'loginFormAttrRegex' in NewPasswordModel.jsm const loginExpr = /login|log in|log on|log-on|sign in|sigin|sign\/in|sign-in|sign on|sign-on/i; diff --git a/toolkit/components/passwordmgr/LoginManager.shared.mjs b/toolkit/components/passwordmgr/LoginManager.shared.mjs index b0122f71265e..d50c53cbad74 100644 --- a/toolkit/components/passwordmgr/LoginManager.shared.mjs +++ b/toolkit/components/passwordmgr/LoginManager.shared.mjs @@ -34,7 +34,7 @@ class Logic { /** * Test whether associated labels of the element have the keyword. - * This is a simplified rule of hasLabelMatchingRegex in NewPasswordModel.sys.mjs + * This is a simplified rule of hasLabelMatchingRegex in NewPasswordModel.jsm */ static hasLabelMatchingRegex(element, regex) { return regex.test(element.labels?.[0]?.textContent); diff --git a/toolkit/components/passwordmgr/LoginManager.sys.mjs b/toolkit/components/passwordmgr/LoginManager.sys.mjs index 538d7c63e141..b95f3ada8b43 100644 --- a/toolkit/components/passwordmgr/LoginManager.sys.mjs +++ b/toolkit/components/passwordmgr/LoginManager.sys.mjs @@ -21,7 +21,7 @@ ChromeUtils.defineLazyGetter(lazy, "log", () => { const MS_PER_DAY = 24 * 60 * 60 * 1000; if (Services.appinfo.processType !== Services.appinfo.PROCESS_TYPE_DEFAULT) { - throw new Error("LoginManager.sys.mjs should only run in the parent process"); + throw new Error("LoginManager.jsm should only run in the parent process"); } export function LoginManager() { diff --git a/toolkit/components/passwordmgr/LoginManagerAuthPrompter.sys.mjs b/toolkit/components/passwordmgr/LoginManagerAuthPrompter.sys.mjs index f56ec80d5ee2..4dd42885ff7a 100644 --- a/toolkit/components/passwordmgr/LoginManagerAuthPrompter.sys.mjs +++ b/toolkit/components/passwordmgr/LoginManagerAuthPrompter.sys.mjs @@ -86,7 +86,7 @@ XPCOMUtils.defineLazyPreferenceGetter( /** * Implements nsIPromptFactory * - * Invoked by [toolkit/components/prompts/src/Prompter.sys.mjs] + * Invoked by [toolkit/components/prompts/src/Prompter.jsm] */ export function LoginManagerAuthPromptFactory() { Services.obs.addObserver(this, "passwordmgr-crypto-login", true); @@ -795,7 +795,7 @@ LoginManagerAuthPrompter.prototype = { .then(ok => (result = ok)) .finally(() => (closed = true)); Services.tm.spinEventLoopUntilOrQuit( - "LoginManagerAuthPrompter.sys.mjs:promptAuth", + "LoginManagerAuthPrompter.jsm:promptAuth", () => closed ); return result; diff --git a/toolkit/components/pictureinpicture/content/player.js b/toolkit/components/pictureinpicture/content/player.js index d306494d923c..fdd13f8955dc 100644 --- a/toolkit/components/pictureinpicture/content/player.js +++ b/toolkit/components/pictureinpicture/content/player.js @@ -45,7 +45,7 @@ const BOTTOM_LEFT_QUADRANT = 3; const BOTTOM_RIGHT_QUADRANT = 4; /** - * Public function to be called from PictureInPicture.sys.mjs. This is the main + * Public function to be called from PictureInPicture.jsm. This is the main * entrypoint for initializing the player window. * * @param {Number} id @@ -61,7 +61,7 @@ function setupPlayer(id, wgp, videoRef) { } /** - * Public function to be called from PictureInPicture.sys.mjs. This update the + * Public function to be called from PictureInPicture.jsm. This update the * controls based on whether or not the video is playing. * * @param {Boolean} isPlaying @@ -72,7 +72,7 @@ function setIsPlayingState(isPlaying) { } /** - * Public function to be called from PictureInPicture.sys.mjs. This update the + * Public function to be called from PictureInPicture.jsm. This update the * controls based on whether or not the video is muted. * * @param {Boolean} isMuted diff --git a/toolkit/components/places/Bookmarks.sys.mjs b/toolkit/components/places/Bookmarks.sys.mjs index 02d9c270fada..97416db6d519 100644 --- a/toolkit/components/places/Bookmarks.sys.mjs +++ b/toolkit/components/places/Bookmarks.sys.mjs @@ -230,7 +230,7 @@ export var Bookmarks = Object.freeze({ if (addedTime > now) { modTime = now; } - let insertInfo = validateBookmarkObject("Bookmarks.sys.mjs: insert", info, { + let insertInfo = validateBookmarkObject("Bookmarks.jsm: insert", info, { type: { defaultValue: this.TYPE_BOOKMARK }, index: { defaultValue: this.DEFAULT_INDEX }, url: { @@ -488,7 +488,7 @@ export var Bookmarks = Object.freeze({ } try { insertInfo = validateBookmarkObject( - "Bookmarks.sys.mjs: insertTree", + "Bookmarks.jsm: insertTree", info, insertInfo ); @@ -681,7 +681,7 @@ export var Bookmarks = Object.freeze({ // The info object is first validated here to ensure it's consistent, then // it's compared to the existing item to remove any properties that don't // need to be updated. - let updateInfo = validateBookmarkObject("Bookmarks.sys.mjs: update", info, { + let updateInfo = validateBookmarkObject("Bookmarks.jsm: update", info, { guid: { required: true }, index: { requiredIf: b => b.hasOwnProperty("parentGuid"), @@ -722,27 +722,23 @@ export var Bookmarks = Object.freeze({ Math.max(item.lastModified, updateInfo.dateAdded) ); } - updateInfo = validateBookmarkObject( - "Bookmarks.sys.mjs: update", - updateInfo, - { - url: { validIf: () => item.type == this.TYPE_BOOKMARK }, - title: { - validIf: () => - [this.TYPE_BOOKMARK, this.TYPE_FOLDER].includes(item.type), - }, - lastModified: { - defaultValue: lastModifiedDefault, - validIf: b => - b.lastModified >= now || - b.lastModified >= (b.dateAdded || item.dateAdded), - }, - dateAdded: { defaultValue: item.dateAdded }, - } - ); + updateInfo = validateBookmarkObject("Bookmarks.jsm: update", updateInfo, { + url: { validIf: () => item.type == this.TYPE_BOOKMARK }, + title: { + validIf: () => + [this.TYPE_BOOKMARK, this.TYPE_FOLDER].includes(item.type), + }, + lastModified: { + defaultValue: lastModifiedDefault, + validIf: b => + b.lastModified >= now || + b.lastModified >= (b.dateAdded || item.dateAdded), + }, + dateAdded: { defaultValue: item.dateAdded }, + }); return lazy.PlacesUtils.withConnectionWrapper( - "Bookmarks.sys.mjs: update", + "Bookmarks.jsm: update", async db => { let parent; if (updateInfo.hasOwnProperty("parentGuid")) { @@ -1035,7 +1031,7 @@ export var Bookmarks = Object.freeze({ lazy.PlacesSyncUtils.bookmarks.determineSyncChangeDelta(source); await lazy.PlacesUtils.withConnectionWrapper( - "Bookmarks.sys.mjs: moveToFolder", + "Bookmarks.jsm: moveToFolder", async db => { const lastModified = new Date(); @@ -1287,10 +1283,7 @@ export var Bookmarks = Object.freeze({ // Even if we ignore any other unneeded property, we still validate any // known property to reduce likelihood of hidden bugs. - let removeInfo = validateBookmarkObject( - "Bookmarks.sys.mjs: remove", - info - ); + let removeInfo = validateBookmarkObject("Bookmarks.jsm: remove", info); removeInfos.push(removeInfo); } @@ -1379,7 +1372,7 @@ export var Bookmarks = Object.freeze({ } return lazy.PlacesUtils.withConnectionWrapper( - "Bookmarks.sys.mjs: eraseEverything", + "Bookmarks.jsm: eraseEverything", async function (db) { let urls; await db.executeTransaction(async function () { @@ -1559,7 +1552,7 @@ export var Bookmarks = Object.freeze({ // Even if we ignore any other unneeded property, we still validate any // known property to reduce likelihood of hidden bugs. let fetchInfo = validateBookmarkObject( - "Bookmarks.sys.mjs: fetch", + "Bookmarks.jsm: fetch", info, behavior ); @@ -1702,7 +1695,7 @@ export var Bookmarks = Object.freeze({ * } */ async fetchTags() { - // TODO: Once the tagging API is implemented in Bookmarks.sys.mjs, we can cache + // TODO: Once the tagging API is implemented in Bookmarks.jsm, we can cache // the list of tags, instead of querying every time. let db = await lazy.PlacesUtils.promiseDBConnection(); let rows = await db.executeCached( @@ -1749,7 +1742,7 @@ export var Bookmarks = Object.freeze({ */ reorder(parentGuid, orderedChildrenGuids, options = {}) { let info = { guid: parentGuid }; - info = validateBookmarkObject("Bookmarks.sys.mjs: reorder", info, { + info = validateBookmarkObject("Bookmarks.jsm: reorder", info, { guid: { required: true }, }); @@ -2111,7 +2104,7 @@ async function updateBookmark( function insertBookmark(item, parent) { return lazy.PlacesUtils.withConnectionWrapper( - "Bookmarks.sys.mjs: insertBookmark", + "Bookmarks.jsm: insertBookmark", async function (db) { // If a guid was not provided, generate one, so we won't need to fetch the // bookmark just after having created it. @@ -2209,7 +2202,7 @@ function insertBookmark(item, parent) { function insertBookmarkTree(items, source, parent, urls, lastAddedForParent) { return lazy.PlacesUtils.withConnectionWrapper( - "Bookmarks.sys.mjs: insertBookmarkTree", + "Bookmarks.jsm: insertBookmarkTree", async function (db) { await db.executeTransaction(async function transaction() { await lazy.PlacesUtils.maybeInsertManyPlaces(db, urls); @@ -2360,7 +2353,7 @@ async function queryBookmarks(info) { } return lazy.PlacesUtils.withConnectionWrapper( - "Bookmarks.sys.mjs: queryBookmarks", + "Bookmarks.jsm: queryBookmarks", async function (db) { // _id, _childCount, _grandParentId and _parentId fields // are required to be in the result by the converting function @@ -2429,7 +2422,7 @@ async function fetchBookmark(info, options = {}) { return query(options.db); } return lazy.PlacesUtils.withConnectionWrapper( - "Bookmarks.sys.mjs: fetchBookmark", + "Bookmarks.jsm: fetchBookmark", query ); } @@ -2461,7 +2454,7 @@ async function fetchBookmarkByPosition(info, options = {}) { return query(db); } return lazy.PlacesUtils.withConnectionWrapper( - "Bookmarks.sys.mjs: fetchBookmarkByPosition", + "Bookmarks.jsm: fetchBookmarkByPosition", query ); } @@ -2509,7 +2502,7 @@ async function fetchBookmarksByTags(info, options = {}) { return query(db); } return lazy.PlacesUtils.withConnectionWrapper( - "Bookmarks.sys.mjs: fetchBookmarksByTags", + "Bookmarks.jsm: fetchBookmarksByTags", query ); } @@ -2539,7 +2532,7 @@ async function fetchBookmarksByGUIDPrefix(info, options = {}) { return query(db); } return lazy.PlacesUtils.withConnectionWrapper( - "Bookmarks.sys.mjs: fetchBookmarksByGUIDPrefix", + "Bookmarks.jsm: fetchBookmarksByGUIDPrefix", query ); } @@ -2581,7 +2574,7 @@ async function fetchBookmarksByURL(info, options = {}) { return query(db); } return lazy.PlacesUtils.withConnectionWrapper( - "Bookmarks.sys.mjs: fetchBookmarksByURL", + "Bookmarks.jsm: fetchBookmarksByURL", query ); } @@ -2614,14 +2607,14 @@ async function fetchBookmarksByParentGUID(info, options = {}) { return query(db); } return lazy.PlacesUtils.withConnectionWrapper( - "Bookmarks.sys.mjs: fetchBookmarksByParentGUID", + "Bookmarks.jsm: fetchBookmarksByParentGUID", query ); } function fetchRecentBookmarks(numberOfItems) { return lazy.PlacesUtils.withConnectionWrapper( - "Bookmarks.sys.mjs: fetchRecentBookmarks", + "Bookmarks.jsm: fetchRecentBookmarks", async function (db) { let rows = await db.executeCached( `SELECT b.guid, IFNULL(p.guid, '') AS parentGuid, b.position AS 'index', @@ -2674,7 +2667,7 @@ async function fetchBookmarksByParent(db, info) { function removeBookmarks(items, options) { return lazy.PlacesUtils.withConnectionWrapper( - "Bookmarks.sys.mjs: removeBookmarks", + "Bookmarks.jsm: removeBookmarks", async function (db) { let urls = []; @@ -2787,7 +2780,7 @@ function removeBookmarks(items, options) { function reorderChildren(parent, orderedChildrenGuids, options) { return lazy.PlacesUtils.withConnectionWrapper( - "Bookmarks.sys.mjs: reorderChildren", + "Bookmarks.jsm: reorderChildren", db => db.executeTransaction(async function () { // Fetch old indices for the notifications. @@ -3321,7 +3314,7 @@ async function retrieveFullBookmarkPath(guid, options = {}) { return query(db); } return lazy.PlacesUtils.withConnectionWrapper( - "Bookmarks.sys.mjs: retrieveFullBookmarkPath", + "Bookmarks.jsm: retrieveFullBookmarkPath", query ); } diff --git a/toolkit/components/places/History.sys.mjs b/toolkit/components/places/History.sys.mjs index fe13043600ea..3f43ca5a5335 100644 --- a/toolkit/components/places/History.sys.mjs +++ b/toolkit/components/places/History.sys.mjs @@ -251,9 +251,8 @@ export var History = Object.freeze({ insert(pageInfo) { let info = lazy.PlacesUtils.validatePageInfo(pageInfo); - return lazy.PlacesUtils.withConnectionWrapper( - "History.sys.mjs: insert", - db => insert(db, info) + return lazy.PlacesUtils.withConnectionWrapper("History.jsm: insert", db => + insert(db, info) ); }, @@ -323,7 +322,7 @@ export var History = Object.freeze({ } return lazy.PlacesUtils.withConnectionWrapper( - "History.sys.mjs: insertMany", + "History.jsm: insertMany", db => insertMany(db, infos, onResult, onError) ); }, @@ -401,7 +400,7 @@ export var History = Object.freeze({ let pages = { guids: guidsSlice, urls: urlsSlice }; let result = await lazy.PlacesUtils.withConnectionWrapper( - "History.sys.mjs: remove", + "History.jsm: remove", db => remove(db, pages, onResult) ); @@ -500,7 +499,7 @@ export var History = Object.freeze({ } return lazy.PlacesUtils.withConnectionWrapper( - "History.sys.mjs: removeVisitsByFilter", + "History.jsm: removeVisitsByFilter", db => removeVisitsByFilter(db, filter, onResult) ); }, @@ -593,7 +592,7 @@ export var History = Object.freeze({ } return lazy.PlacesUtils.withConnectionWrapper( - "History.sys.mjs: removeByFilter", + "History.jsm: removeByFilter", db => removeByFilter(db, filter, onResult) ); }, @@ -645,10 +644,7 @@ export var History = Object.freeze({ * A promise resolved once the operation is complete. */ clear() { - return lazy.PlacesUtils.withConnectionWrapper( - "History.sys.mjs: clear", - clear - ); + return lazy.PlacesUtils.withConnectionWrapper("History.jsm: clear", clear); }, /** @@ -709,7 +705,7 @@ export var History = Object.freeze({ * 1). A null `previewImageURL` will clear the existing value in the * database. * 2). It throws if its length is greater than DB_URL_LENGTH_MAX - * defined in PlacesUtils.sys.mjs. + * defined in PlacesUtils.jsm. * * If a property `annotations` is provided, the annotations will be * updated. Note that: @@ -732,7 +728,7 @@ export var History = Object.freeze({ * If `pageInfo` has neither `description` nor `previewImageURL`. * @throws (Error) * If the length of `pageInfo.previewImageURL` is greater than - * DB_URL_LENGTH_MAX defined in PlacesUtils.sys.mjs. + * DB_URL_LENGTH_MAX defined in PlacesUtils.jsm. */ update(pageInfo) { let info = lazy.PlacesUtils.validatePageInfo(pageInfo, false); @@ -748,9 +744,8 @@ export var History = Object.freeze({ ); } - return lazy.PlacesUtils.withConnectionWrapper( - "History.sys.mjs: update", - db => update(db, info) + return lazy.PlacesUtils.withConnectionWrapper("History.jsm: update", db => + update(db, info) ); }, diff --git a/toolkit/components/places/PlacesExpiration.sys.mjs b/toolkit/components/places/PlacesExpiration.sys.mjs index 2621decdc587..4db494d63e6f 100644 --- a/toolkit/components/places/PlacesExpiration.sys.mjs +++ b/toolkit/components/places/PlacesExpiration.sys.mjs @@ -435,7 +435,7 @@ export function nsPlacesExpiration() { ); this._dbInitializedPromise = lazy.PlacesUtils.withConnectionWrapper( - "PlacesExpiration.sys.mjs: setup", + "PlacesExpiration.jsm: setup", async db => { await db.execute( `CREATE TEMP TABLE expiration_notify ( @@ -758,7 +758,7 @@ nsPlacesExpiration.prototype = { try { let notifications = []; await lazy.PlacesUtils.withConnectionWrapper( - "PlacesExpiration.sys.mjs: expire", + "PlacesExpiration.jsm: expire", async db => { await db.executeTransaction(async () => { for (let queryType in EXPIRATION_QUERIES) { diff --git a/toolkit/components/places/PlacesPreviews.sys.mjs b/toolkit/components/places/PlacesPreviews.sys.mjs index e19bf2a55c3f..73d0d6d95265 100644 --- a/toolkit/components/places/PlacesPreviews.sys.mjs +++ b/toolkit/components/places/PlacesPreviews.sys.mjs @@ -85,7 +85,7 @@ class DeletionHandler { constructor() { // Clear any pending timeouts on shutdown. lazy.PlacesUtils.history.shutdownClient.jsclient.addBlocker( - "PlacesPreviews.sys.mjs::DeletionHandler", + "PlacesPreviews.jsm::DeletionHandler", async () => { this.#shutdownProgress.shuttingDown = true; lazy.clearTimeout(this.#timeoutId); @@ -164,7 +164,7 @@ class DeletionHandler { return p; }, {}); await lazy.PlacesUtils.withConnectionWrapper( - "PlacesPreviews.sys.mjs::ExpirePreviews", + "PlacesPreviews.jsm::ExpirePreviews", async db => { await db.execute( `DELETE FROM moz_previews_tombstones WHERE hash in @@ -288,7 +288,7 @@ export const PlacesPreviews = new (class extends EventEmitter { * Updates the preview for the given page url. The update happens in * background, using a windowless browser with very conservative privacy * settings. Due to this, it may not look exactly like the page that the user - * is normally facing when logged in. See BackgroundPageThumbs.sys.mjs for + * is normally facing when logged in. See BackgroundPageThumbs.jsm for * additional details. * Unless `forceUpdate` is set, the preview is not updated if: * - It was already fetched recently @@ -385,7 +385,7 @@ export const PlacesPreviews = new (class extends EventEmitter { .map(n => n.substring(0, n.lastIndexOf("."))); await lazy.PlacesUtils.withConnectionWrapper( - "PlacesPreviews.sys.mjs::deleteOrphans", + "PlacesPreviews.jsm::deleteOrphans", async db => { await db.execute( ` diff --git a/toolkit/components/places/PlacesSyncUtils.sys.mjs b/toolkit/components/places/PlacesSyncUtils.sys.mjs index caa5054885af..6da1b9124364 100644 --- a/toolkit/components/places/PlacesSyncUtils.sys.mjs +++ b/toolkit/components/places/PlacesSyncUtils.sys.mjs @@ -11,7 +11,7 @@ ChromeUtils.defineESModuleGetters(lazy, { /** * This module exports functions for Sync to use when applying remote - * records. The calls are similar to those in `Bookmarks.sys.mjs` and + * records. The calls are similar to those in `Bookmarks.jsm` and * `nsINavBookmarksService`, with special handling for * tags, keywords, synced annotations, and missing parents. */ @@ -1405,7 +1405,7 @@ function validateChangeRecord(name, changeRecord, behavior) { } // Similar to the private `fetchBookmarksByParent` implementation in -// `Bookmarks.sys.mjs`. +// `Bookmarks.jsm`. var fetchChildGuids = async function (db, parentGuid) { let rows = await db.executeCached( ` diff --git a/toolkit/components/places/Shutdown.h b/toolkit/components/places/Shutdown.h index 0a9674bf0647..3e5612a4541f 100644 --- a/toolkit/components/places/Shutdown.h +++ b/toolkit/components/places/Shutdown.h @@ -28,8 +28,8 @@ class Database; * PHASE 2 (Modern clients shutdown) * Modern clients should instead register as a blocker by passing a promise to - * nsINavHistoryService::shutdownClient (for example see Sanitizer.sys.mjs), so - * they block Places shutdown until the promise is resolved. + * nsINavHistoryService::shutdownClient (for example see Sanitizer.jsm), so they + * block Places shutdown until the promise is resolved. * When profile-change-teardown is observed by async shutdown, it calls * ClientsShutdownBlocker::BlockShutdown. This class is registered as a teardown * phase blocker in Database::Init (see Database::mClientsShutdown). diff --git a/toolkit/components/places/mozIAsyncHistory.idl b/toolkit/components/places/mozIAsyncHistory.idl index 88690b4798e3..90c32b1090b0 100644 --- a/toolkit/components/places/mozIAsyncHistory.idl +++ b/toolkit/components/places/mozIAsyncHistory.idl @@ -128,11 +128,11 @@ interface mozIVisitedStatusCallback : nsISupports /** * This interface contains APIs for cpp consumers. - * Javascript consumers should look at History.sys.mjs instead, + * Javascript consumers should look at History.jsm instead, * that is exposed through PlacesUtils.history. * * If you're evaluating adding a new history API, it should - * usually go to History.sys.mjs, unless it needs to do long and + * usually go to History.jsm, unless it needs to do long and * expensive work in a batch, then it could be worth doing * that in History.cpp. */ diff --git a/toolkit/components/prompts/docs/nsIPromptService-reference.rst b/toolkit/components/prompts/docs/nsIPromptService-reference.rst index c1412a30f845..9879cd753a48 100644 --- a/toolkit/components/prompts/docs/nsIPromptService-reference.rst +++ b/toolkit/components/prompts/docs/nsIPromptService-reference.rst @@ -2,7 +2,7 @@ Prompt Service Reference ======================== -This is the JSDoc from the Prompter.sys.mjs implementation. You can find the full +This is the JSDoc from the Prompter.jsm implementation. You can find the full interface definition in `nsIPromptService.idl `_. diff --git a/toolkit/components/prompts/src/Prompter.sys.mjs b/toolkit/components/prompts/src/Prompter.sys.mjs index a0b5edca2f4a..4c8030c27b37 100644 --- a/toolkit/components/prompts/src/Prompter.sys.mjs +++ b/toolkit/components/prompts/src/Prompter.sys.mjs @@ -1058,7 +1058,7 @@ class ModalPrompter { closed = true; }); Services.tm.spinEventLoopUntilOrQuit( - "prompts/Prompter.sys.mjs:openPromptSync", + "prompts/Prompter.jsm:openPromptSync", () => closed ); } diff --git a/toolkit/components/resistfingerprinting/RFPHelper.sys.mjs b/toolkit/components/resistfingerprinting/RFPHelper.sys.mjs index 223c0259b76d..a085aa492a4e 100644 --- a/toolkit/components/resistfingerprinting/RFPHelper.sys.mjs +++ b/toolkit/components/resistfingerprinting/RFPHelper.sys.mjs @@ -20,7 +20,7 @@ var logConsole; function log(msg) { if (!logConsole) { logConsole = console.createInstance({ - prefix: "RFPHelper", + prefix: "RFPHelper.jsm", maxLogLevelPref: "privacy.resistFingerprinting.jsmloglevel", }); } diff --git a/toolkit/components/satchel/FormHistoryStartup.sys.mjs b/toolkit/components/satchel/FormHistoryStartup.sys.mjs index aa76f16dc552..104756c5832e 100644 --- a/toolkit/components/satchel/FormHistoryStartup.sys.mjs +++ b/toolkit/components/satchel/FormHistoryStartup.sys.mjs @@ -67,7 +67,7 @@ export class FormHistoryStartup { target, }) { // This case is only used for the search field. There is a - // similar algorithm in FormHistoryParent.sys.mjs that uses + // similar algorithm in FormHistoryParent.jsm that uses // sendQuery for other form fields. const instance = (this._queryInstance = {}); diff --git a/toolkit/components/satchel/nsFormFillController.cpp b/toolkit/components/satchel/nsFormFillController.cpp index 1bcbde08dfec..7872ab36c86e 100644 --- a/toolkit/components/satchel/nsFormFillController.cpp +++ b/toolkit/components/satchel/nsFormFillController.cpp @@ -85,7 +85,7 @@ nsFormFillController::nsFormFillController() mListNode(nullptr), // The amount of time a context menu event supresses showing a // popup from a focus event in ms. This matches the threshold in - // toolkit/components/passwordmgr/LoginManagerChild.sys.mjs. + // toolkit/components/passwordmgr/LoginManagerChild.jsm. mFocusAfterRightClickThreshold(400), mTimeout(50), mMinResultsForPopup(1), diff --git a/toolkit/components/taskscheduler/TaskScheduler.sys.mjs b/toolkit/components/taskscheduler/TaskScheduler.sys.mjs index 4de5d0a76c8e..2225328c4172 100644 --- a/toolkit/components/taskscheduler/TaskScheduler.sys.mjs +++ b/toolkit/components/taskscheduler/TaskScheduler.sys.mjs @@ -93,7 +93,7 @@ export var TaskScheduler = { * * options.disabled * If true the task will be created disabled, so that it will not be run. - * Ignored on macOS: see comments in TaskSchedulerMacOSImpl.sys.mjs. + * Ignored on macOS: see comments in TaskSchedulerMacOSImpl.jsm. * Default false, intended for tests. * * options.executionTimeoutSec diff --git a/toolkit/components/taskscheduler/TaskSchedulerMacOSImpl.sys.mjs b/toolkit/components/taskscheduler/TaskSchedulerMacOSImpl.sys.mjs index 3cd5b5c51d94..d47d3c5c14ed 100644 --- a/toolkit/components/taskscheduler/TaskSchedulerMacOSImpl.sys.mjs +++ b/toolkit/components/taskscheduler/TaskSchedulerMacOSImpl.sys.mjs @@ -36,7 +36,7 @@ ChromeUtils.defineLazyGetter(lazy, "log", () => { /** * Task generation and management for macOS, using `launchd` via `launchctl`. * - * Implements the API exposed in TaskScheduler.sys.mjs + * Implements the API exposed in TaskScheduler.jsm * Not intended for external use, this is in a separate module to ship the code only * on macOS, and to expose for testing. */ diff --git a/toolkit/components/taskscheduler/TaskSchedulerWinImpl.sys.mjs b/toolkit/components/taskscheduler/TaskSchedulerWinImpl.sys.mjs index 009fc18c387e..8d9c15c31494 100644 --- a/toolkit/components/taskscheduler/TaskSchedulerWinImpl.sys.mjs +++ b/toolkit/components/taskscheduler/TaskSchedulerWinImpl.sys.mjs @@ -22,7 +22,7 @@ XPCOMUtils.defineLazyServiceGetters(lazy, { /** * Task generation and management for Windows, using Task Scheduler 2.0 (taskschd). * - * Implements the API exposed in TaskScheduler.sys.mjs + * Implements the API exposed in TaskScheduler.jsm * Not intended for external use, this is in a separate module to ship the code only * on Windows, and to expose for testing. */ diff --git a/toolkit/components/telemetry/Histograms.json b/toolkit/components/telemetry/Histograms.json index 223b96f082e7..68db4fa42a7e 100644 --- a/toolkit/components/telemetry/Histograms.json +++ b/toolkit/components/telemetry/Histograms.json @@ -7011,7 +7011,7 @@ "n_values": 50, "releaseChannelCollection": "opt-out", "bug_numbers": [353804], - "description": "Update: background update check result code except for no updates found (after we already have an update ready). Possible codes are enumerated by constants starting with CHK_ in toolkit/mozapps/update/UpdateTelemetry.sys.mjs" + "description": "Update: background update check result code except for no updates found (after we already have an update ready). Possible codes are enumerated by constants starting with CHK_ in toolkit/mozapps/update/UpdateTelemetry.jsm" }, "UPDATE_CHECK_EXTENDED_ERROR_EXTERNAL": { "record_in_processes": ["main"], @@ -7757,7 +7757,7 @@ "n_values": 30, "releaseChannelCollection": "opt-out", "bug_numbers": [1137447], - "description": "Update: the update wizard page displayed when the UI was closed (mapped in toolkit/mozapps/update/UpdateTelemetry.sys.mjs)" + "description": "Update: the update wizard page displayed when the UI was closed (mapped in toolkit/mozapps/update/UpdateTelemetry.jsm)" }, "UPDATE_NOTIFICATION_SHOWN": { "record_in_processes": ["main"], @@ -8322,7 +8322,7 @@ "kind": "enumerated", "n_values": 15, "releaseChannelCollection": "opt-out", - "description": "The browser that data is pulled from. The values correspond to the internal browser ID (see MigrationUtils.sys.mjs)" + "description": "The browser that data is pulled from. The values correspond to the internal browser ID (see MigrationUtils.jsm)" }, "FX_MIGRATION_ERRORS": { "record_in_processes": ["main"], @@ -8402,7 +8402,7 @@ "high": 60000, "releaseChannelCollection": "opt-out", "keyed": true, - "description": "Accumulated timer delay (variance between when the timer was expected to fire and when it actually fired) in milliseconds as an indicator for decreased main-thread responsiveness while importing bookmarks from another browser, keyed by the name of the browser (see gAvailableMigratorKeys in MigrationUtils.sys.mjs). The import is happening on a background thread and should ideally not affect the UI noticeably." + "description": "Accumulated timer delay (variance between when the timer was expected to fire and when it actually fired) in milliseconds as an indicator for decreased main-thread responsiveness while importing bookmarks from another browser, keyed by the name of the browser (see gAvailableMigratorKeys in MigrationUtils.jsm). The import is happening on a background thread and should ideally not affect the UI noticeably." }, "FX_MIGRATION_HISTORY_JANK_MS": { "record_in_processes": ["main"], @@ -8415,7 +8415,7 @@ "high": 60000, "releaseChannelCollection": "opt-out", "keyed": true, - "description": "Accumulated timer delay (variance between when the timer was expected to fire and when it actually fired) in milliseconds as an indicator for decreased main-thread responsiveness while importing history from another browser, keyed by the name of the browser (see gAvailableMigratorKeys in MigrationUtils.sys.mjs). The import is happening on a background thread and should ideally not affect the UI noticeably." + "description": "Accumulated timer delay (variance between when the timer was expected to fire and when it actually fired) in milliseconds as an indicator for decreased main-thread responsiveness while importing history from another browser, keyed by the name of the browser (see gAvailableMigratorKeys in MigrationUtils.jsm). The import is happening on a background thread and should ideally not affect the UI noticeably." }, "FX_MIGRATION_LOGINS_JANK_MS": { "record_in_processes": ["main"], @@ -8428,7 +8428,7 @@ "high": 60000, "releaseChannelCollection": "opt-out", "keyed": true, - "description": "Accumulated timer delay (variance between when the timer was expected to fire and when it actually fired) in milliseconds as an indicator for decreased main-thread responsiveness while importing logins / passwords from another browser, keyed by the name of the browser (see gAvailableMigratorKeys in MigrationUtils.sys.mjs). The import is happening on a background thread and should ideally not affect the UI noticeably. The time with the blocking Keychain dialog on macOS can skew this data." + "description": "Accumulated timer delay (variance between when the timer was expected to fire and when it actually fired) in milliseconds as an indicator for decreased main-thread responsiveness while importing logins / passwords from another browser, keyed by the name of the browser (see gAvailableMigratorKeys in MigrationUtils.jsm). The import is happening on a background thread and should ideally not affect the UI noticeably. The time with the blocking Keychain dialog on macOS can skew this data." }, "FX_MIGRATION_BOOKMARKS_QUANTITY": { "record_in_processes": ["main"], @@ -12479,7 +12479,7 @@ "expires_in_version": "default", "kind": "enumerated", "n_values": 10, - "description": "BACKGROUND THUMBNAILS: Reason the capture completed (see TEL_CAPTURE_DONE_* constants in BackgroundPageThumbs.sys.mjs)" + "description": "BACKGROUND THUMBNAILS: Reason the capture completed (see TEL_CAPTURE_DONE_* constants in BackgroundPageThumbs.jsm)" }, "FX_THUMBNAILS_BG_CAPTURE_PAGE_LOAD_TIME_MS": { "record_in_processes": ["main", "content"], diff --git a/toolkit/components/telemetry/Scalars.yaml b/toolkit/components/telemetry/Scalars.yaml index 858d2556e485..1028e83d5e2d 100644 --- a/toolkit/components/telemetry/Scalars.yaml +++ b/toolkit/components/telemetry/Scalars.yaml @@ -5016,7 +5016,7 @@ update: to be moved from the downloading update directory to the ready update directory. This probe counts the results that we get when attempting to perform this file move. Valid values for the keys for this probe are - stored in the MOVE_RESULT_* values in UpdateTelemetry.sys.mjs. + stored in the MOVE_RESULT_* values in UpdateTelemetry.jsm. expires: never kind: uint keyed: true diff --git a/toolkit/components/telemetry/TelemetryStartup.sys.mjs b/toolkit/components/telemetry/TelemetryStartup.sys.mjs index dae0c268db90..139366bd5ecc 100644 --- a/toolkit/components/telemetry/TelemetryStartup.sys.mjs +++ b/toolkit/components/telemetry/TelemetryStartup.sys.mjs @@ -12,7 +12,7 @@ ChromeUtils.defineESModuleGetters(lazy, { /** * TelemetryStartup is needed to forward the "profile-after-change" notification - * to TelemetryController.sys.mjs. + * to TelemetryController.jsm. */ export function TelemetryStartup() {} diff --git a/toolkit/components/telemetry/docs/data/health-ping.rst b/toolkit/components/telemetry/docs/data/health-ping.rst index 8b1be7810532..e5655924e11f 100644 --- a/toolkit/components/telemetry/docs/data/health-ping.rst +++ b/toolkit/components/telemetry/docs/data/health-ping.rst @@ -38,7 +38,7 @@ The client id is submitted with this ping. Send behavior ------------- -``HealthPing.sys.mjs`` tracks several problems: +``HealthPing.jsm`` tracks several problems: * The size of other assembled pings exceeds the ping limit. * Failures while sending other pings. diff --git a/toolkit/components/telemetry/docs/obsolete/fhr/architecture.rst b/toolkit/components/telemetry/docs/obsolete/fhr/architecture.rst index bfdce6daab46..2e9c37f3d344 100644 --- a/toolkit/components/telemetry/docs/obsolete/fhr/architecture.rst +++ b/toolkit/components/telemetry/docs/obsolete/fhr/architecture.rst @@ -4,11 +4,11 @@ Architecture ============ -``healthreporter.sys.mjs`` contains the main interface for FHR, the +``healthreporter.jsm`` contains the main interface for FHR, the ``HealthReporter`` type. An instance of this is created by the ``data_reporting_service``. -``providers.sys.mjs`` contains numerous ``Metrics.Provider`` and +``providers.jsm`` contains numerous ``Metrics.Provider`` and ``Metrics.Measurement`` used for collecting application metrics. If you are looking for the FHR probes, this is where they are. @@ -157,7 +157,7 @@ See ``HealthReportComponents.manifest`` for providers defined in this directory. Essentially, the category manager receives the name of a JS type and the -URI of a sys.mjs to import that exports this symbol. At run-time, the +URI of a JSM to import that exports this symbol. At run-time, the providers registered in the category manager are instantiated. Providers are registered via the category manager to make registration diff --git a/toolkit/components/telemetry/docs/obsolete/fhr/dataformat.rst b/toolkit/components/telemetry/docs/obsolete/fhr/dataformat.rst index 8a9d9a591b47..730d7514b8c8 100644 --- a/toolkit/components/telemetry/docs/obsolete/fhr/dataformat.rst +++ b/toolkit/components/telemetry/docs/obsolete/fhr/dataformat.rst @@ -1700,7 +1700,7 @@ Version 1 was introduced with Firefox 37 and includes the following properties: state Corresponds to either a STATE_USER_* string or a STATE_INTERNAL_* string in - FxaMigration.sys.mjs. This reflects a state where we are waiting for the user, + FxaMigration.jsm. This reflects a state where we are waiting for the user, or waiting for some internal process to complete on the way to completing the migration. diff --git a/toolkit/components/translations/translations.d.ts b/toolkit/components/translations/translations.d.ts index cc8d462a9cd0..ec1e899af42a 100644 --- a/toolkit/components/translations/translations.d.ts +++ b/toolkit/components/translations/translations.d.ts @@ -187,7 +187,7 @@ export namespace Bergamot { /** * The client to interact with RemoteSettings. - * See services/settings/RemoteSettingsClient.sys.mjs + * See services/settings/RemoteSettingsClient.jsm */ interface RemoteSettingsClient { on: Function, diff --git a/toolkit/components/url-classifier/UrlClassifierListManager.sys.mjs b/toolkit/components/url-classifier/UrlClassifierListManager.sys.mjs index a96c6bad15ff..410e203672f5 100644 --- a/toolkit/components/url-classifier/UrlClassifierListManager.sys.mjs +++ b/toolkit/components/url-classifier/UrlClassifierListManager.sys.mjs @@ -70,7 +70,7 @@ function PROT_ListManager() { this.updateCheckers_ = {}; this.requestBackoffs_ = {}; - // This is only used by testcases to ensure SafeBrowsing.sys.mjs is inited + // This is only used by testcases to ensure SafeBrowsing.jsm is inited this.registered = false; this.dbService_ = Cc["@mozilla.org/url-classifier/dbservice;1"].getService( diff --git a/toolkit/components/url-classifier/UrlClassifierRemoteSettingsService.sys.mjs b/toolkit/components/url-classifier/UrlClassifierRemoteSettingsService.sys.mjs index 55f6efd5f048..42f8cf272a09 100644 --- a/toolkit/components/url-classifier/UrlClassifierRemoteSettingsService.sys.mjs +++ b/toolkit/components/url-classifier/UrlClassifierRemoteSettingsService.sys.mjs @@ -55,7 +55,7 @@ UrlClassifierRemoteSettingsService.prototype = { }); }, - // Parse the update request. See UrlClassifierListManager.sys.mjs makeUpdateRequest + // Parse the update request. See UrlClassifierListManager.jsm makeUpdateRequest // for more details about how we build the update request. // // @param aRequest the request payload of the update request diff --git a/toolkit/components/url-classifier/nsIUrlListManager.idl b/toolkit/components/url-classifier/nsIUrlListManager.idl index fb2408ca3dbd..6bf01020ee0d 100644 --- a/toolkit/components/url-classifier/nsIUrlListManager.idl +++ b/toolkit/components/url-classifier/nsIUrlListManager.idl @@ -88,7 +88,7 @@ interface nsIUrlListManager : nsISupports /** * Return true if someone registers a table, this is used by testcase - * to figure out it SafeBrowsing.sys.mjs is initialized. + * to figure out it SafeBrowsing.jsm is initialized. */ boolean isRegistered(); }; diff --git a/toolkit/components/utils/ClientEnvironment.sys.mjs b/toolkit/components/utils/ClientEnvironment.sys.mjs index 1c6bbfbabaf2..7f1b4cb97027 100644 --- a/toolkit/components/utils/ClientEnvironment.sys.mjs +++ b/toolkit/components/utils/ClientEnvironment.sys.mjs @@ -216,7 +216,7 @@ export class ClientEnvironmentBase { /** * Gets the windows build number by querying the OS directly. The initial - * version was copied from toolkit/components/telemetry/app/TelemetryEnvironment.sys.mjs + * version was copied from toolkit/components/telemetry/app/TelemetryEnvironment.jsm * @returns {number | null} The build number, or null on non-Windows platform or if there is an error. */ get windowsBuildNumber() { diff --git a/toolkit/content/aboutLogging.js b/toolkit/content/aboutLogging.js index daff10fbec6b..4d797e6201a6 100644 --- a/toolkit/content/aboutLogging.js +++ b/toolkit/content/aboutLogging.js @@ -50,7 +50,7 @@ function moduleEnvVarPresent() { * as markers. * * [1]: The keys of the `presets` object defined in - * https://searchfox.org/mozilla-central/source/devtools/client/performance-new/shared/background.sys.mjs + * https://searchfox.org/mozilla-central/source/devtools/client/performance-new/shared/background.jsm.js */ const gOsSpecificLoggingPresets = (() => { diff --git a/toolkit/content/widgets/datetimebox.js b/toolkit/content/widgets/datetimebox.js index 04ed398bd74b..28b32fddfa35 100644 --- a/toolkit/content/widgets/datetimebox.js +++ b/toolkit/content/widgets/datetimebox.js @@ -5,7 +5,7 @@ "use strict"; // This is a UA widget. It runs in per-origin UA widget scope, -// to be loaded by UAWidgetsChild.sys.mjs. +// to be loaded by UAWidgetsChild.jsm. /* * This is the class of entry. It will construct the actual implementation diff --git a/toolkit/content/widgets/menu.js b/toolkit/content/widgets/menu.js index 1a55d799b60f..f787747a0174 100644 --- a/toolkit/content/widgets/menu.js +++ b/toolkit/content/widgets/menu.js @@ -129,7 +129,7 @@ }; // The element is used for rendering inside of , - // See SelectParentHelper.sys.mjs. + // See SelectParentHelper.jsm. class MozMenuCaption extends MozMenuBaseMixin(MozXULElement) { static get inheritedAttributes() { return { diff --git a/toolkit/content/widgets/textrecognition.js b/toolkit/content/widgets/textrecognition.js index c517f7bfb124..887d5767707c 100644 --- a/toolkit/content/widgets/textrecognition.js +++ b/toolkit/content/widgets/textrecognition.js @@ -4,7 +4,7 @@ "use strict"; // This is a UA widget. It runs in per-origin UA widget scope, -// to be loaded by UAWidgetsChild.sys.mjs. +// to be loaded by UAWidgetsChild.jsm. this.TextRecognitionWidget = class { /** diff --git a/toolkit/content/widgets/videocontrols.js b/toolkit/content/widgets/videocontrols.js index 73a32164aaa5..60572ae02653 100644 --- a/toolkit/content/widgets/videocontrols.js +++ b/toolkit/content/widgets/videocontrols.js @@ -5,7 +5,7 @@ "use strict"; // This is a UA widget. It runs in per-origin UA widget scope, -// to be loaded by UAWidgetsChild.sys.mjs. +// to be loaded by UAWidgetsChild.jsm. /* * This is the class of entry. It will construct the actual implementation diff --git a/toolkit/crashreporter/docs/index.rst b/toolkit/crashreporter/docs/index.rst index fe1af45d8fd9..464edcf62b1e 100644 --- a/toolkit/crashreporter/docs/index.rst +++ b/toolkit/crashreporter/docs/index.rst @@ -155,7 +155,7 @@ with information about the crash. Submission of child process crashes is handled by application code. This code prompts the user to submit crashes in context-appropriate UI and then -submits the crashes using ``CrashSubmit.sys.mjs``. +submits the crashes using ``CrashSubmit.jsm``. Memory Reports ============== diff --git a/toolkit/modules/AppConstants.sys.mjs b/toolkit/modules/AppConstants.sys.mjs index a180ea788d66..36b26056ecb9 100644 --- a/toolkit/modules/AppConstants.sys.mjs +++ b/toolkit/modules/AppConstants.sys.mjs @@ -6,9 +6,7 @@ * You can obtain one at http://mozilla.org/MPL/2.0/. */ const lazy = {}; -ChromeUtils.defineESModuleGetters(lazy, { - AddonManager: "resource://gre/modules/AddonManager.sys.mjs" -}); +ChromeUtils.defineModuleGetter(lazy, "AddonManager", "resource://gre/modules/AddonManager.jsm"); // Immutable for export. export var AppConstants = Object.freeze({ diff --git a/toolkit/modules/Console.sys.mjs b/toolkit/modules/Console.sys.mjs index c3964fa84066..5fb4f750f41c 100644 --- a/toolkit/modules/Console.sys.mjs +++ b/toolkit/modules/Console.sys.mjs @@ -6,7 +6,7 @@ * Define a 'console' API to roughly match the implementation provided by * Firebug. * This module helps cases where code is shared between the web and Firefox. - * See also Browser.sys.mjs for an implementation of other web constants to help + * See also Browser.jsm for an implementation of other web constants to help * sharing code between the web and firefox; * * The API is only be a rough approximation for 3 reasons: diff --git a/toolkit/modules/docs/AsyncShutdown.rst b/toolkit/modules/docs/AsyncShutdown.rst index 4b0c5ef0f9ea..8d9e0d4388c2 100644 --- a/toolkit/modules/docs/AsyncShutdown.rst +++ b/toolkit/modules/docs/AsyncShutdown.rst @@ -58,8 +58,8 @@ The following snippet presents an example of a client of FooService that has a s // Some client of FooService called FooClient - const { FooService } = ChromeUtils.importESModule( - "resource://gre/modules/FooService.sys.mjs" + const { FooService } = ChromeUtils.import( + "resource://gre/modules/FooService.jsm" ); // FooService.shutdown is the `client` capability of a `Barrier`. @@ -117,8 +117,8 @@ The following snippet presents FooClient2, a more sophisticated client of FooSer // Some client of FooService called FooClient2 - const { FooService } = ChromeUtils.importESModule( - "resource://gre/modules/FooService.sys.mjs" + const { FooService } = ChromeUtils.import( + "resource://gre/modules/FooService.jsm" ); FooService.shutdown.addBlocker( diff --git a/toolkit/modules/third_party/fathom/README b/toolkit/modules/third_party/fathom/README index 7c2f0980fa59..5f7ba3b4cb4d 100644 --- a/toolkit/modules/third_party/fathom/README +++ b/toolkit/modules/third_party/fathom/README @@ -14,4 +14,4 @@ In order to regenerate this file, do the following: $ make bundleESModule $ export MOZ_FATHOM="../../mozilla-central/toolkit/modules/third_party/fathom" - $ cat $MOZ_FATHOM/fx-header dist/fathom.js > $MOZ_FATHOM/fathom.mjs + $ cat $MOZ_FATHOM/fx-header dist/fathom.js > $MOZ_FATHOM/fathom.jsm diff --git a/toolkit/modules/third_party/fathom/fathom.mjs b/toolkit/modules/third_party/fathom/fathom.mjs index be6001326121..c1d984a9e3e2 100644 --- a/toolkit/modules/third_party/fathom/fathom.mjs +++ b/toolkit/modules/third_party/fathom/fathom.mjs @@ -1,5 +1,5 @@ /* -DO NOT TOUCH fathom.mjs DIRECTLY. See the README for instructions. +DO NOT TOUCH fathom.jsm DIRECTLY. See the README for instructions. */ /* This Source Code Form is subject to the terms of the Mozilla Public diff --git a/toolkit/mozapps/downloads/DownloadUtils.sys.mjs b/toolkit/mozapps/downloads/DownloadUtils.sys.mjs index 6684a7369961..3bf97f3c9e59 100644 --- a/toolkit/mozapps/downloads/DownloadUtils.sys.mjs +++ b/toolkit/mozapps/downloads/DownloadUtils.sys.mjs @@ -610,7 +610,7 @@ function convertTimeUnitsUnits(timeValue, aIndex) { * Error message to log or an array of strings to concat */ // function log(aMsg) { -// let msg = "DownloadUtils.sys.mjs: " + (aMsg.join ? aMsg.join("") : aMsg); +// let msg = "DownloadUtils.jsm: " + (aMsg.join ? aMsg.join("") : aMsg); // Services.console.logStringMessage(msg); // dump(msg + "\n"); // } diff --git a/toolkit/mozapps/extensions/AddonManager.sys.mjs b/toolkit/mozapps/extensions/AddonManager.sys.mjs index c69cf4029ee9..e4e51885cf24 100644 --- a/toolkit/mozapps/extensions/AddonManager.sys.mjs +++ b/toolkit/mozapps/extensions/AddonManager.sys.mjs @@ -1610,10 +1610,10 @@ var AddonManagerInternal = { // Temporary hack until bug 520124 lands. // We can get here during synchronous startup, at which point it's - // considered unsafe (and therefore disallowed by AddonManager.sys.mjs) to + // considered unsafe (and therefore disallowed by AddonManager.jsm) to // access providers that haven't been initialized yet. Since this is when // XPIProvider is starting up, XPIProvider can't access itself via APIs - // going through AddonManager.sys.mjs. Thankfully, this is the only use + // going through AddonManager.jsm. Thankfully, this is the only use // of this API, and we know it's safe to use this API with both // providers; so we have this hack to allow bypassing the normal // safetey guard. diff --git a/toolkit/mozapps/extensions/internal/AddonRepository.sys.mjs b/toolkit/mozapps/extensions/internal/AddonRepository.sys.mjs index e53e4af7a483..e854e04b3ce2 100644 --- a/toolkit/mozapps/extensions/internal/AddonRepository.sys.mjs +++ b/toolkit/mozapps/extensions/internal/AddonRepository.sys.mjs @@ -78,7 +78,7 @@ import { Log } from "resource://gre/modules/Log.sys.mjs"; const LOGGER_ID = "addons.repository"; // Create a new logger for use by the Addons Repository -// (Requires AddonManager.sys.mjs) +// (Requires AddonManager.jsm) var logger = Log.repository.getLogger(LOGGER_ID); function convertHTMLToPlainText(html) { diff --git a/toolkit/mozapps/extensions/internal/AddonTestUtils.sys.mjs b/toolkit/mozapps/extensions/internal/AddonTestUtils.sys.mjs index f53d32092dc6..9433278eb6bf 100644 --- a/toolkit/mozapps/extensions/internal/AddonTestUtils.sys.mjs +++ b/toolkit/mozapps/extensions/internal/AddonTestUtils.sys.mjs @@ -298,7 +298,7 @@ export var AddonTestUtils = { // And scan for changes at startup Services.prefs.setIntPref("extensions.startupScanScopes", 15); - // By default, don't cache add-ons in AddonRepository.sys.mjs + // By default, don't cache add-ons in AddonRepository.jsm Services.prefs.setBoolPref("extensions.getAddons.cache.enabled", false); // Point update checks to the local machine for fast failures @@ -1743,7 +1743,7 @@ export var AddonTestUtils = { * @param {object} extension * The return value of ExtensionTestUtils.loadExtension. * For browser tests, see mochitest/tests/SimpleTest/ExtensionTestUtils.js - * For xpcshell tests, see toolkit/components/extensions/ExtensionXPCShellUtils.sys.mjs + * For xpcshell tests, see toolkit/components/extensions/ExtensionXPCShellUtils.jsm * @param {object} [options] * Optional options. * @param {boolean} [options.expectPending = false] diff --git a/toolkit/mozapps/extensions/internal/AddonUpdateChecker.sys.mjs b/toolkit/mozapps/extensions/internal/AddonUpdateChecker.sys.mjs index 5b7b10a7641c..a3935a26f99e 100644 --- a/toolkit/mozapps/extensions/internal/AddonUpdateChecker.sys.mjs +++ b/toolkit/mozapps/extensions/internal/AddonUpdateChecker.sys.mjs @@ -26,7 +26,7 @@ import { Log } from "resource://gre/modules/Log.sys.mjs"; const LOGGER_ID = "addons.update-checker"; // Create a new logger for use by the Addons Update Checker -// (Requires AddonManager.sys.mjs) +// (Requires AddonManager.jsm) var logger = Log.repository.getLogger(LOGGER_ID); /** diff --git a/toolkit/mozapps/extensions/internal/XPIDatabase.sys.mjs b/toolkit/mozapps/extensions/internal/XPIDatabase.sys.mjs index af0b02444a47..5d1d2c19706b 100644 --- a/toolkit/mozapps/extensions/internal/XPIDatabase.sys.mjs +++ b/toolkit/mozapps/extensions/internal/XPIDatabase.sys.mjs @@ -117,7 +117,7 @@ const nsIFile = Components.Constructor( ); // Create a new logger for use by the Addons XPI Provider Utils -// (Requires AddonManager.sys.mjs) +// (Requires AddonManager.jsm) var logger = Log.repository.getLogger(LOGGER_ID); const FILE_JSON_DB = "extensions.json"; diff --git a/toolkit/mozapps/extensions/internal/XPIInstall.sys.mjs b/toolkit/mozapps/extensions/internal/XPIInstall.sys.mjs index d1167fcf5f9f..5f7fba24ad9e 100644 --- a/toolkit/mozapps/extensions/internal/XPIInstall.sys.mjs +++ b/toolkit/mozapps/extensions/internal/XPIInstall.sys.mjs @@ -168,7 +168,7 @@ import { Log } from "resource://gre/modules/Log.sys.mjs"; const LOGGER_ID = "addons.xpi"; // Create a new logger for use by all objects in this Addons XPI Provider module -// (Requires AddonManager.sys.mjs) +// (Requires AddonManager.jsm) var logger = Log.repository.getLogger(LOGGER_ID); // Stores the ID of the theme which was selected during the last session, diff --git a/toolkit/mozapps/extensions/internal/XPIProvider.sys.mjs b/toolkit/mozapps/extensions/internal/XPIProvider.sys.mjs index 12d4fa1172f4..d5ffd06d1127 100644 --- a/toolkit/mozapps/extensions/internal/XPIProvider.sys.mjs +++ b/toolkit/mozapps/extensions/internal/XPIProvider.sys.mjs @@ -185,7 +185,7 @@ import { Log } from "resource://gre/modules/Log.sys.mjs"; const LOGGER_ID = "addons.xpi"; // Create a new logger for use by all objects in this Addons XPI Provider module -// (Requires AddonManager.sys.mjs) +// (Requires AddonManager.jsm) var logger = Log.repository.getLogger(LOGGER_ID); /** diff --git a/toolkit/mozapps/update/BackgroundUpdate.sys.mjs b/toolkit/mozapps/update/BackgroundUpdate.sys.mjs index 3022c9ffde02..28d0fc853857 100644 --- a/toolkit/mozapps/update/BackgroundUpdate.sys.mjs +++ b/toolkit/mozapps/update/BackgroundUpdate.sys.mjs @@ -570,7 +570,7 @@ export var BackgroundUpdate = { }; try { - // Interacting with `TaskScheduler.sys.mjs` can throw, so we'll catch. + // Interacting with `TaskScheduler.jsm` can throw, so we'll catch. if (!enabled) { lazy.log.info( `${SLUG}: not scheduling background update: '${JSON.stringify( diff --git a/toolkit/mozapps/update/UpdateService.sys.mjs b/toolkit/mozapps/update/UpdateService.sys.mjs index 34bf1b9e19ae..808946f819bd 100644 --- a/toolkit/mozapps/update/UpdateService.sys.mjs +++ b/toolkit/mozapps/update/UpdateService.sys.mjs @@ -193,7 +193,7 @@ const WRITE_ERROR_DIR_ACCESS_DENIED = 68; const WRITE_ERROR_DELETE_BACKUP = 69; const WRITE_ERROR_EXTRACT = 70; -// Error codes 80 through 99 are reserved for UpdateService.sys.mjs and are not +// Error codes 80 through 99 are reserved for UpdateService.jsm and are not // defined in common/updatererrors.h const ERR_UPDATER_CRASHED = 89; const ERR_OLDER_VERSION_OR_SAME_BUILD = 90; @@ -1907,7 +1907,7 @@ function pingStateAndStatusCodes(aUpdate, aStartup, aStatus) { stateCode = 13; break; // Note: Do not use stateCode 14 here. It is defined in - // UpdateTelemetry.sys.mjs + // UpdateTelemetry.jsm default: stateCode = 1; } @@ -3399,7 +3399,7 @@ UpdateService.prototype = { // See Bug 1599590. // Note that we exit unconditionally here if we are only doing manual // update checks, because manual update checking uses a completely - // different code path (AppUpdater.sys.mjs creates its own nsIUpdateChecker), + // different code path (AppUpdater.jsm creates its own nsIUpdateChecker), // bypassing this function completely. AUSTLMY.pingCheckCode(this._pingSuffix, AUSTLMY.CHK_DISABLED_BY_POLICY); return false; diff --git a/toolkit/mozapps/update/UpdateTelemetry.sys.mjs b/toolkit/mozapps/update/UpdateTelemetry.sys.mjs index f3c350267c9f..20fb0ab4a431 100644 --- a/toolkit/mozapps/update/UpdateTelemetry.sys.mjs +++ b/toolkit/mozapps/update/UpdateTelemetry.sys.mjs @@ -316,7 +316,7 @@ export var AUSTLMY = { * This value is also used to determine the key for the keyed scalar * update.bitshresult (key is either "COMPLETE" or "PARTIAL") * @param aError - * The BitsError that occurred. See Bits.sys.mjs for details on BitsError. + * The BitsError that occurred. See Bits.jsm for details on BitsError. */ pingBitsError: function UT_pingBitsError(aIsComplete, aError) { if (AppConstants.platform != "win") { diff --git a/toolkit/mozapps/update/common/updatererrors.h b/toolkit/mozapps/update/common/updatererrors.h index d3abf14ffeac..f2663d5b577d 100644 --- a/toolkit/mozapps/update/common/updatererrors.h +++ b/toolkit/mozapps/update/common/updatererrors.h @@ -10,7 +10,7 @@ #define OK 0 // Error codes that are no longer used should not be used again unless they -// aren't used in client code (e.g. UpdateService.sys.mjs, updates.js, etc.). +// aren't used in client code (e.g. UpdateService.jsm, updates.js, etc.). #define MAR_ERROR_EMPTY_ACTION_LIST 1 #define LOADSOURCE_ERROR_WRONG_SIZE 2 @@ -26,8 +26,8 @@ // Error codes 10-14 are related to memory allocation failures. // Note: If more memory allocation error codes are added, the implementation of -// isMemoryAllocationErrorCode in UpdateService.sys.mjs should be updated to -// account for them. +// isMemoryAllocationErrorCode in UpdateService.jsm should be updated to account +// for them. #define READ_STRINGS_MEM_ERROR 10 #define ARCHIVE_READER_MEM_ERROR 11 #define BSPATCH_MEM_ERROR 12 @@ -49,8 +49,8 @@ // Error codes 24-33 and 49-58 are for the Windows maintenance service. // Note: If more maintenance service error codes are added, the implementations -// of IsServiceSpecificErrorCode in updater.cpp and UpdateService.sys.mjs should -// be updated to account for them. +// of IsServiceSpecificErrorCode in updater.cpp and UpdateService.jsm should be +// updated to account for them. #define SERVICE_UPDATER_COULD_NOT_BE_STARTED 24 #define SERVICE_NOT_ENOUGH_COMMAND_LINE_ARGS 25 #define SERVICE_UPDATER_SIGN_ERROR 26 @@ -79,8 +79,8 @@ // Error codes 24-33 and 49-58 are for the Windows maintenance service. // Note: If more maintenance service error codes are added, the implementations -// of IsServiceSpecificErrorCode in updater.cpp and UpdateService.sys.mjs should -// be updated to account for them. +// of IsServiceSpecificErrorCode in updater.cpp and UpdateService.jsm should be +// updated to account for them. #define SERVICE_COULD_NOT_COPY_UPDATER 49 #define SERVICE_STILL_APPLYING_TERMINATED 50 #define SERVICE_STILL_APPLYING_NO_EXIT_CODE 51 @@ -112,7 +112,7 @@ #define INVALID_CALLBACK_DIR_ERROR 78 #define UPDATE_STATUS_UNCHANGED 79 -// Error codes 80 through 99 are reserved for UpdateService.sys.mjs +// Error codes 80 through 99 are reserved for UpdateService.jsm // The following error codes are only used by updater.exe // when a fallback key exists for tests. @@ -125,6 +125,6 @@ #define SILENT_UPDATE_NEEDED_ELEVATION_ERROR 105 #define WRITE_ERROR_BACKGROUND_TASK_SHARING_VIOLATION 106 -// Error codes 110 and 111 are reserved for UpdateService.sys.mjs +// Error codes 110 and 111 are reserved for UpdateService.jsm #endif // UPDATEERRORS_H diff --git a/toolkit/mozapps/update/docs/BackgroundUpdates.rst b/toolkit/mozapps/update/docs/BackgroundUpdates.rst index d8a154cb393e..7f97f58c7472 100644 --- a/toolkit/mozapps/update/docs/BackgroundUpdates.rst +++ b/toolkit/mozapps/update/docs/BackgroundUpdates.rst @@ -65,7 +65,7 @@ observe and control these settings. But there are some other pieces of state which absolutely must come from a profile, such as the telemetry client ID and logging level settings (see -`BackgroundTasksUtils.sys.mjs `__). +`BackgroundTasksUtils.jsm `__). This means that, in addition to our per-installation prefs, we also need to be able to identify and load a profile. To do that, we leverage `the profile @@ -137,7 +137,7 @@ API `__. For platform-specific scheduling details, see the -`TaskScheduler.sys.mjs `__ +`TaskScheduler.jsm `__ module. These background tasks are scheduled per OS user and run with that user’s @@ -177,7 +177,7 @@ visible to users: see `bug 1775132 After setting up this profile and reading all the configuration we need into it, the regular -`UpdateService.sys.mjs `__ +`UpdateService.jsm `__ check process is initiated. To the greatest extent possible, this process is identical to what happens during any regular browsing session. diff --git a/toolkit/mozapps/update/updater/updater.cpp b/toolkit/mozapps/update/updater/updater.cpp index 111609415933..4b6d847f200b 100644 --- a/toolkit/mozapps/update/updater/updater.cpp +++ b/toolkit/mozapps/update/updater/updater.cpp @@ -2704,20 +2704,21 @@ static int ReadMARChannelIDsFromBuffer(char* aChannels, */ static int GetAcceptableChannelIDs(MARChannelStringTable* aMARStrings) { int rv = UPDATE_SETTINGS_FILE_CHANNEL; -# ifdef XP_MACOSX - if (auto marChannels = UpdateSettingsUtil::GetAcceptedMARChannelsValue()) { +#ifdef XP_MACOSX + if (auto marChannels = + UpdateSettingsUtil::GetAcceptedMARChannelsValue()) { rv = ReadMARChannelIDsFromBuffer(marChannels->data(), aMARStrings); } -# else +#else NS_tchar updateSettingsPath[MAXPATHLEN]; NS_tsnprintf(updateSettingsPath, sizeof(updateSettingsPath) / sizeof(updateSettingsPath[0]), NS_T("%s/update-settings.ini"), gInstallDirPath); rv = ReadMARChannelIDsFromPath(updateSettingsPath, aMARStrings); -# endif +#endif return rv == OK ? OK : UPDATE_SETTINGS_FILE_CHANNEL; } -#endif // MOZ_VERIFY_MAR_SIGNATURE +#endif // MOZ_VERIFY_MAR_SIGNATURE static int GetUpdateFileName(NS_tchar* fileName, int maxChars) { NS_tsnprintf(fileName, maxChars, NS_T("%s/update.mar"), gPatchDirPath); @@ -2998,8 +2999,8 @@ int NS_main(int argc, NS_tchar** argv) { printf("Error: %d\n", rv); return 1; #else - printf("Not Applicable: No support for signature verification\n"); - return 0; + printf("Not Applicable: No support for signature verification\n"); + return 0; #endif } @@ -3782,7 +3783,7 @@ int NS_main(int argc, NS_tchar** argv) { } // Set an error so we don't get into an update loop when the callback // runs. This will be reset to pending by handleUpdateFailure in - // UpdateService.sys.mjs. + // UpdateService.jsm. WriteStatusFile(SILENT_UPDATE_NEEDED_ELEVATION_ERROR); LOG(("Skipping update to avoid UAC prompt from background task.")); output_finish(); diff --git a/toolkit/themes/shared/global-shared.css b/toolkit/themes/shared/global-shared.css index 320245afbefd..178eab24f2d5 100644 --- a/toolkit/themes/shared/global-shared.css +++ b/toolkit/themes/shared/global-shared.css @@ -360,7 +360,7 @@ button.text-link .button-text { --panel-padding: 0; --panel-background: rgba(249,249,250,.8) no-repeat center var(--autoscroll-background-image); --panel-shadow-margin: 4px; - /* Set pointer-events: none; so that mousemove events can be handled by AutoScrollChild.sys.mjs. */ + /* Set pointer-events: none; so that mousemove events can be handled by AutoScrollChild.jsm. */ pointer-events: none; } diff --git a/tools/profiler/core/platform.cpp b/tools/profiler/core/platform.cpp index 8ce029402b8a..11c6d10724a6 100644 --- a/tools/profiler/core/platform.cpp +++ b/tools/profiler/core/platform.cpp @@ -275,7 +275,7 @@ class GeckoJavaSampler featureStringArray.length()); // 128 * 1024 * 1024 is the entries preset that is given in - // devtools/client/performance-new/shared/background.sys.mjs + // devtools/client/performance-new/shared/background.jsm.js profiler_start(PowerOfTwo32(128 * 1024 * 1024), 5.0, features, filtersTemp.begin(), filtersTemp.length(), 0, Nothing()); } diff --git a/uriloader/exthandler/nsExternalHelperAppService.h b/uriloader/exthandler/nsExternalHelperAppService.h index 1f77e095dbfa..205f73cfa127 100644 --- a/uriloader/exthandler/nsExternalHelperAppService.h +++ b/uriloader/exthandler/nsExternalHelperAppService.h @@ -544,8 +544,8 @@ class nsExternalAppHandler final : public nsIStreamListener, const nsString& path); /** - * Set in HelperAppDlg.sys.mjs. This is always null after the user has chosen - * an action. + * Set in HelperAppDlg.jsm. This is always null after the user has chosen an + * action. */ nsCOMPtr mDialogProgressListener; /** -- 2.11.4.GIT