Bug 1779982 - Migrate toolkit/components/places and browser/components/places to ESM. r=mak

Differential Revision: https://phabricator.services.mozilla.com/D152004
This commit is contained in:
Mark Banner 2022-07-20 10:36:49 +00:00
Родитель 47cd6c5eb6
Коммит 374f18ee33
34 изменённых файлов: 72 добавлений и 127 удалений

Просмотреть файл

@ -62,7 +62,7 @@ const startupPhases = {
"resource:///modules/ShellService.jsm",
"resource://gre/modules/NewTabUtils.jsm",
"resource://gre/modules/PageThumbs.jsm",
"resource://gre/modules/PlacesUtils.jsm",
"resource://gre/modules/PlacesUtils.sys.mjs",
"resource://gre/modules/Preferences.jsm",
"resource://gre/modules/SearchService.sys.mjs",
"resource://gre/modules/Sqlite.jsm",
@ -80,14 +80,14 @@ const startupPhases = {
"resource://gre/modules/Blocklist.jsm",
// Bug 1391495 - BrowserWindowTracker.jsm is intermittently used.
// "resource:///modules/BrowserWindowTracker.jsm",
"resource://gre/modules/BookmarkHTMLUtils.jsm",
"resource://gre/modules/Bookmarks.jsm",
"resource://gre/modules/BookmarkHTMLUtils.sys.mjs",
"resource://gre/modules/Bookmarks.sys.mjs",
"resource://gre/modules/ContextualIdentityService.jsm",
"resource://gre/modules/FxAccounts.jsm",
"resource://gre/modules/FxAccountsStorage.jsm",
"resource://gre/modules/PlacesBackups.jsm",
"resource://gre/modules/PlacesExpiration.jsm",
"resource://gre/modules/PlacesSyncUtils.jsm",
"resource://gre/modules/PlacesBackups.sys.mjs",
"resource://gre/modules/PlacesExpiration.sys.mjs",
"resource://gre/modules/PlacesSyncUtils.sys.mjs",
"resource://gre/modules/PushComponents.jsm",
]),
services: new Set(["@mozilla.org/browser/nav-bookmarks-service;1"]),

Просмотреть файл

@ -272,7 +272,7 @@ var whitelist = [
// find the references)
{ file: "chrome://browser/content/screenshots/copied-notification.svg" },
{ file: "resource://app/modules/SnapshotSelector.jsm" },
{ file: "resource://app/modules/SnapshotSelector.sys.mjs" },
// toolkit/xre/MacRunFromDmgUtils.mm
{ file: "resource://gre/localization/en-US/toolkit/global/run-from-dmg.ftl" },

Просмотреть файл

@ -4,8 +4,6 @@
"use strict";
var EXPORTED_SYMBOLS = ["CommonNames"];
const { XPCOMUtils } = ChromeUtils.importESModule(
"resource://gre/modules/XPCOMUtils.sys.mjs"
);
@ -292,7 +290,7 @@ const MAX_HOSTNAME_PARTS = 2;
* a common name cannot be fetched, the origin is returned with its TLD
* stripped, e.g. "stackoverflow".
*/
class CommonNames {
export class CommonNames {
/**
* Returns a snapshot's common name.
*

Просмотреть файл

@ -2,8 +2,6 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this file,
* You can obtain one at http://mozilla.org/MPL/2.0/. */
const EXPORTED_SYMBOLS = ["DomainGroupBuilder"];
const { XPCOMUtils } = ChromeUtils.importESModule(
"resource://gre/modules/XPCOMUtils.sys.mjs"
);
@ -18,7 +16,7 @@ XPCOMUtils.defineLazyModuleGetters(lazy, {
/**
* A builder for snapshot groups based on domains.
*/
const DomainGroupBuilder = new (class DomainGroupBuilder {
export const DomainGroupBuilder = new (class DomainGroupBuilder {
/**
* @type {Map<string, object>}
* A map of domains to snapshot group data for groups that are currently in

Просмотреть файл

@ -4,8 +4,6 @@
"use strict";
var EXPORTED_SYMBOLS = ["Interactions"];
const { XPCOMUtils } = ChromeUtils.importESModule(
"resource://gre/modules/XPCOMUtils.sys.mjs"
);
@ -581,7 +579,7 @@ class _Interactions {
]);
}
const Interactions = new _Interactions();
export const Interactions = new _Interactions();
/**
* Store interactions data in the Places database.

Просмотреть файл

@ -4,8 +4,6 @@
"use strict";
var EXPORTED_SYMBOLS = ["InteractionsBlocklist"];
const { XPCOMUtils } = ChromeUtils.importESModule(
"resource://gre/modules/XPCOMUtils.sys.mjs"
);
@ -286,4 +284,4 @@ class _InteractionsBlocklist {
}
}
const InteractionsBlocklist = new _InteractionsBlocklist();
export const InteractionsBlocklist = new _InteractionsBlocklist();

Просмотреть файл

@ -4,8 +4,6 @@
"use strict";
var EXPORTED_SYMBOLS = ["InteractionsChild"];
const { XPCOMUtils } = ChromeUtils.importESModule(
"resource://gre/modules/XPCOMUtils.sys.mjs"
);
@ -26,7 +24,7 @@ XPCOMUtils.defineLazyModuleGetters(lazy, {
* Listens for interactions in the child process and passes information to the
* parent.
*/
class InteractionsChild extends JSWindowActorChild {
export class InteractionsChild extends JSWindowActorChild {
#progressListener;
#currentURL;

Просмотреть файл

@ -4,8 +4,6 @@
"use strict";
var EXPORTED_SYMBOLS = ["InteractionsParent"];
const lazy = {};
ChromeUtils.defineModuleGetter(
@ -18,7 +16,7 @@ ChromeUtils.defineModuleGetter(
* Receives messages from InteractionsChild and passes them to the appropriate
* interactions object.
*/
class InteractionsParent extends JSWindowActorParent {
export class InteractionsParent extends JSWindowActorParent {
receiveMessage(msg) {
switch (msg.name) {
case "Interactions:PageLoaded":

Просмотреть файл

@ -2,8 +2,6 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this file,
* You can obtain one at http://mozilla.org/MPL/2.0/. */
const EXPORTED_SYMBOLS = ["PinnedGroupBuilder"];
const { XPCOMUtils } = ChromeUtils.importESModule(
"resource://gre/modules/XPCOMUtils.sys.mjs"
);
@ -18,7 +16,7 @@ XPCOMUtils.defineLazyModuleGetters(lazy, {
/**
* A builder for snapshot groups based on pinned snapshots.
*/
const PinnedGroupBuilder = new (class PinnedGroupBuilder {
export const PinnedGroupBuilder = new (class PinnedGroupBuilder {
/**
* @type {Map<string, object>}
* A map of domains to snapshot group data for groups that are currently in

Просмотреть файл

@ -3,8 +3,6 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
var EXPORTED_SYMBOLS = ["PlacesUIUtils"];
const { XPCOMUtils } = ChromeUtils.importESModule(
"resource://gre/modules/XPCOMUtils.sys.mjs"
);
@ -421,7 +419,7 @@ class BookmarkState {
}
}
var PlacesUIUtils = {
export var PlacesUIUtils = {
BookmarkState,
_bookmarkToolbarTelemetryListening: false,
LAST_USED_FOLDERS_META_KEY: "bookmarks/lastusedfolders",

Просмотреть файл

@ -4,8 +4,6 @@
"use strict";
var EXPORTED_SYMBOLS = ["SnapshotGroups"];
const { XPCOMUtils } = ChromeUtils.importESModule(
"resource://gre/modules/XPCOMUtils.sys.mjs"
);
@ -70,7 +68,7 @@ XPCOMUtils.defineLazyPreferenceGetter(
* places-snapshot-group-updated, data: id of the snapshot group.
* places-snapshot-group-deleted, data: id of the snapshot group.
*/
const SnapshotGroups = new (class SnapshotGroups {
export const SnapshotGroups = new (class SnapshotGroups {
constructor() {}
/**

Просмотреть файл

@ -2,8 +2,6 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this file,
* You can obtain one at http://mozilla.org/MPL/2.0/. */
const EXPORTED_SYMBOLS = ["SnapshotMonitor"];
const { XPCOMUtils } = ChromeUtils.importESModule(
"resource://gre/modules/XPCOMUtils.sys.mjs"
);
@ -57,7 +55,7 @@ const EXPIRE_CHUNK_SIZE = 10;
* Monitors changes in snapshots (additions, deletions, etc) and triggers
* the snapshot group builders to run as necessary.
*/
const SnapshotMonitor = new (class SnapshotMonitor {
export const SnapshotMonitor = new (class SnapshotMonitor {
/**
* @type {number}
*/

Просмотреть файл

@ -2,8 +2,6 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this file,
* You can obtain one at http://mozilla.org/MPL/2.0/. */
const EXPORTED_SYMBOLS = ["SnapshotScorer"];
const { XPCOMUtils } = ChromeUtils.importESModule(
"resource://gre/modules/XPCOMUtils.sys.mjs"
);
@ -54,7 +52,7 @@ XPCOMUtils.defineLazyGetter(lazy, "logConsole", function() {
* expected relevancy to the user. This order is subsequently used to display
* the candidates.
*/
const SnapshotScorer = new (class SnapshotScorer {
export const SnapshotScorer = new (class SnapshotScorer {
/**
* @type {Map}
* A map of function suffixes to relevancy points. The suffixes are prefixed

Просмотреть файл

@ -1,8 +1,6 @@
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this file,
* You can obtain one at http://mozilla.org/MPL/2.0/. */
const EXPORTED_SYMBOLS = ["SnapshotSelector"];
const { XPCOMUtils } = ChromeUtils.importESModule(
"resource://gre/modules/XPCOMUtils.sys.mjs"
);
@ -78,7 +76,7 @@ XPCOMUtils.defineLazyGetter(lazy, "logConsole", function() {
* This component is intentionally decoupled from where the context comes from
* so it can be unit tested.
*/
class SnapshotSelector extends EventEmitter {
export class SnapshotSelector extends EventEmitter {
/**
* All of the active selectors.
*/

Просмотреть файл

@ -4,8 +4,6 @@
"use strict";
var EXPORTED_SYMBOLS = ["Snapshots"];
const { XPCOMUtils } = ChromeUtils.importESModule(
"resource://gre/modules/XPCOMUtils.sys.mjs"
);
@ -198,7 +196,7 @@ XPCOMUtils.defineLazyPreferenceGetter(
* - places-snapshots-deleted, data: JSON encoded array of urls
* Sent when a snapshot is removed.
*/
const Snapshots = new (class Snapshots {
export const Snapshots = new (class Snapshots {
USER_PERSISTED = {
// The snapshot was created automatically.
NO: 0,

Просмотреть файл

@ -19,22 +19,22 @@ JAR_MANIFESTS += ["jar.mn"]
SPHINX_TREES["/browser/places"] = "docs"
EXTRA_JS_MODULES += [
"CommonNames.jsm",
"DomainGroupBuilder.jsm",
"Interactions.jsm",
"InteractionsBlocklist.jsm",
"PinnedGroupBuilder.jsm",
"PlacesUIUtils.jsm",
"SnapshotGroups.jsm",
"SnapshotMonitor.jsm",
"Snapshots.jsm",
"SnapshotScorer.jsm",
"SnapshotSelector.jsm",
"CommonNames.sys.mjs",
"DomainGroupBuilder.sys.mjs",
"Interactions.sys.mjs",
"InteractionsBlocklist.sys.mjs",
"PinnedGroupBuilder.sys.mjs",
"PlacesUIUtils.sys.mjs",
"SnapshotGroups.sys.mjs",
"SnapshotMonitor.sys.mjs",
"Snapshots.sys.mjs",
"SnapshotScorer.sys.mjs",
"SnapshotSelector.sys.mjs",
]
FINAL_TARGET_FILES.actors += [
"InteractionsChild.jsm",
"InteractionsParent.jsm",
"InteractionsChild.sys.mjs",
"InteractionsParent.sys.mjs",
]
with Files("**"):

Просмотреть файл

@ -56,8 +56,6 @@
* both require the content (= title) before actually creating it.
*/
var EXPORTED_SYMBOLS = ["BookmarkHTMLUtils"];
const { NetUtil } = ChromeUtils.import("resource://gre/modules/NetUtil.jsm");
const { FileUtils } = ChromeUtils.import(
"resource://gre/modules/FileUtils.jsm"
@ -124,7 +122,7 @@ function notifyObservers(aTopic, aInitialImport) {
);
}
var BookmarkHTMLUtils = Object.freeze({
export var BookmarkHTMLUtils = Object.freeze({
/**
* Loads the current bookmarks hierarchy from a "bookmarks.html" file.
*

Просмотреть файл

@ -2,8 +2,6 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this file,
* You can obtain one at http://mozilla.org/MPL/2.0/. */
var EXPORTED_SYMBOLS = ["BookmarkJSONUtils"];
const { PlacesUtils } = ChromeUtils.import(
"resource://gre/modules/PlacesUtils.jsm"
);
@ -47,7 +45,7 @@ function generateHash(aString) {
return cryptoHash.finish(true).replace(/\//g, "-");
}
var BookmarkJSONUtils = Object.freeze({
export var BookmarkJSONUtils = Object.freeze({
/**
* Import bookmarks from a url.
*

Просмотреть файл

@ -57,8 +57,6 @@
* @see nsINavBookmarkObserver
*/
var EXPORTED_SYMBOLS = ["Bookmarks"];
const lazy = {};
ChromeUtils.defineModuleGetter(
@ -100,7 +98,7 @@ const MATCH_ANYWHERE_UNMODIFIED =
Ci.mozIPlacesAutoComplete.MATCH_ANYWHERE_UNMODIFIED;
const BEHAVIOR_BOOKMARK = Ci.mozIPlacesAutoComplete.BEHAVIOR_BOOKMARK;
var Bookmarks = Object.freeze({
export var Bookmarks = Object.freeze({
/**
* Item's type constants.
* These should stay consistent with nsINavBookmarksService.idl

Просмотреть файл

@ -4,8 +4,6 @@
"use strict";
var EXPORTED_SYMBOLS = ["ExtensionSearchHandler"];
// Used to keep track of all of the registered keywords, where each keyword is
// mapped to a KeywordInfo instance.
let gKeywordMap = new Map();
@ -90,7 +88,7 @@ class InputSession {
}
}
var ExtensionSearchHandler = Object.freeze({
export var ExtensionSearchHandler = Object.freeze({
MSG_INPUT_STARTED: "webext-omnibox-input-started",
MSG_INPUT_CHANGED: "webext-omnibox-input-changed",
MSG_INPUT_ENTERED: "webext-omnibox-input-entered",

Просмотреть файл

@ -68,8 +68,6 @@
* @see PlacesObservers
*/
var EXPORTED_SYMBOLS = ["History"];
const { XPCOMUtils } = ChromeUtils.importESModule(
"resource://gre/modules/XPCOMUtils.sys.mjs"
);
@ -127,7 +125,7 @@ function notify(observers, notification, args = []) {
}
}
var History = Object.freeze({
export var History = Object.freeze({
ANNOTATION_EXPIRE_NEVER: 4,
// Constants for the type of annotation.
ANNOTATION_TYPE_STRING: 3,

Просмотреть файл

@ -4,8 +4,6 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
var EXPORTED_SYMBOLS = ["PlacesBackups"];
const { XPCOMUtils } = ChromeUtils.importESModule(
"resource://gre/modules/XPCOMUtils.sys.mjs"
);
@ -95,7 +93,7 @@ function getBackupFileForSameDate(aFilename) {
})();
}
var PlacesBackups = {
export var PlacesBackups = {
/**
* Matches the backup filename:
* 0: file name

Просмотреть файл

@ -25,9 +25,7 @@ XPCOMUtils.defineLazyModuleGetters(lazy, {
Sqlite: "resource://gre/modules/Sqlite.jsm",
});
var EXPORTED_SYMBOLS = ["PlacesDBUtils", "PlacesDBUtilsIdleMaintenance"];
var PlacesDBUtils = {
export var PlacesDBUtils = {
_isShuttingDown: false,
_clearTaskQueue: false,
@ -1469,7 +1467,7 @@ async function integrity(dbName) {
}
}
function PlacesDBUtilsIdleMaintenance() {}
export function PlacesDBUtilsIdleMaintenance() {}
PlacesDBUtilsIdleMaintenance.prototype = {
observe(subject, topic, data) {

Просмотреть файл

@ -423,7 +423,7 @@ const EXPIRATION_QUERIES = {
},
};
function nsPlacesExpiration() {
export function nsPlacesExpiration() {
// Allows other components to easily access getPagesLimit.
this.wrappedJSObject = this;
@ -981,5 +981,3 @@ nsPlacesExpiration.prototype = {
"nsISupportsWeakReference",
]),
};
var EXPORTED_SYMBOLS = ["nsPlacesExpiration"];

Просмотреть файл

@ -4,8 +4,6 @@
"use strict";
var EXPORTED_SYMBOLS = ["PlacesPreviews", "PlacesPreviewsHelperService"];
const { EventEmitter } = ChromeUtils.import(
"resource://gre/modules/EventEmitter.jsm"
);
@ -202,7 +200,7 @@ class DeletionHandler {
* format. All the previews are saved into a "places-previews" folder under
* the roaming profile folder.
*/
const PlacesPreviews = new (class extends EventEmitter {
export const PlacesPreviews = new (class extends EventEmitter {
#placesObserver = null;
#deletionHandler = null;
// This is used as a cache to avoid fetching the same preview multiple
@ -446,7 +444,8 @@ const PlacesPreviews = new (class extends EventEmitter {
* Used to exposes nsIPlacesPreviewsHelperService to the moz-page-thumb protocol
* cpp implementation.
*/
function PlacesPreviewsHelperService() {}
export function PlacesPreviewsHelperService() {}
PlacesPreviewsHelperService.prototype = {
classID: Components.ID("{bd0a4d3b-ff26-4d4d-9a62-a513e1c1bf92}"),
QueryInterface: ChromeUtils.generateQI(["nsIPlacesPreviewsHelperService"]),

Просмотреть файл

@ -4,8 +4,6 @@
"use strict";
var EXPORTED_SYMBOLS = ["PlacesSyncUtils"];
const { XPCOMUtils } = ChromeUtils.importESModule(
"resource://gre/modules/XPCOMUtils.sys.mjs"
);
@ -25,7 +23,7 @@ ChromeUtils.defineModuleGetter(
* `nsINavBookmarksService`, with special handling for
* tags, keywords, synced annotations, and missing parents.
*/
var PlacesSyncUtils = {};
export var PlacesSyncUtils = {};
const { SOURCE_SYNC } = Ci.nsINavBookmarksService;

Просмотреть файл

@ -4,8 +4,6 @@
"use strict";
var EXPORTED_SYMBOLS = ["PlacesTransactions"];
/**
* Overview
* --------
@ -306,7 +304,7 @@ XPCOMUtils.defineLazyGetter(
() => new TransactionsHistoryArray()
);
var PlacesTransactions = {
export var PlacesTransactions = {
/**
* @see Batches in the module documentation.
*/

Просмотреть файл

@ -3,8 +3,6 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
var EXPORTED_SYMBOLS = ["PlacesUtils"];
const { AppConstants } = ChromeUtils.import(
"resource://gre/modules/AppConstants.jsm"
);
@ -426,7 +424,7 @@ const PAGEINFO_VALIDATORS = Object.freeze({
},
});
var PlacesUtils = {
export var PlacesUtils = {
// Place entries that are containers, e.g. bookmark folders or queries.
TYPE_X_MOZ_PLACE_CONTAINER: "text/x-moz-place-container",
// Place entries that are bookmark separators.

Просмотреть файл

@ -49,8 +49,6 @@
* issues.
*/
var EXPORTED_SYMBOLS = ["SyncedBookmarksMirror"];
const { XPCOMUtils } = ChromeUtils.importESModule(
"resource://gre/modules/XPCOMUtils.sys.mjs"
);
@ -247,7 +245,7 @@ ProgressTracker.STEPS = {
* changes on the server, and when the user is node reassigned, disables the
* bookmarks engine, or signs out.
*/
class SyncedBookmarksMirror {
export class SyncedBookmarksMirror {
constructor(
db,
wasCorrupt = false,

Просмотреть файл

@ -12,7 +12,7 @@ const TOPIC_SHUTDOWN = "places-shutdown";
/**
* The Places Tagging Service
*/
function TaggingService() {
export function TaggingService() {
this.handlePlacesEvents = this.handlePlacesEvents.bind(this);
// Observe bookmarks changes.
@ -536,7 +536,7 @@ class TagSearch {
}
// Implements nsIAutoCompleteSearch
function TagAutoCompleteSearch() {}
export function TagAutoCompleteSearch() {}
TagAutoCompleteSearch.prototype = {
/*
@ -566,5 +566,3 @@ TagAutoCompleteSearch.prototype = {
classID: Components.ID("{1dcc23b0-d4cb-11dc-9ad6-479d56d89593}"),
QueryInterface: ChromeUtils.generateQI(["nsIAutoCompleteSearch"]),
};
var EXPORTED_SYMBOLS = ["TaggingService", "TagAutoCompleteSearch"];

Просмотреть файл

@ -49,20 +49,20 @@ Classes = [
{
'cid': '{bbc23860-2553-479d-8b78-94d9038334f7}',
'contract_ids': ['@mozilla.org/browser/tagging-service;1'],
'jsm': 'resource://gre/modules/TaggingService.jsm',
'esModule': 'resource://gre/modules/TaggingService.sys.mjs',
'constructor': 'TaggingService',
},
{
'cid': '{1dcc23b0-d4cb-11dc-9ad6-479d56d89593}',
'contract_ids': ['@mozilla.org/autocomplete/search;1?name=places-tag-autocomplete'],
'jsm': 'resource://gre/modules/TaggingService.jsm',
'esModule': 'resource://gre/modules/TaggingService.sys.mjs',
'constructor': 'TagAutoCompleteSearch',
},
{
'cid': '{705a423f-2f69-42f3-b9fe-1517e0dee56f}',
'contract_ids': ['@mozilla.org/places/expiration;1'],
'jsm': 'resource://gre/modules/PlacesExpiration.jsm',
'esModule': 'resource://gre/modules/PlacesExpiration.sys.mjs',
'constructor': 'nsPlacesExpiration',
'categories': {'places-init-complete': 'nsPlacesExpiration'},
},
@ -70,7 +70,7 @@ Classes = [
{
'cid': '{d38926e0-29c1-11eb-8588-0800200c9a66}',
'contract_ids': ['@mozilla.org/places/databaseUtilsIdleMaintenance;1'],
'jsm': 'resource://gre/modules/PlacesDBUtils.jsm',
'esModule': 'resource://gre/modules/PlacesDBUtils.sys.mjs',
'constructor': 'PlacesDBUtilsIdleMaintenance',
'categories': {'idle-daily': 'PlacesDBUtilsIdleMaintenance'},
},
@ -95,7 +95,7 @@ Classes = [
{
'cid': '{bd0a4d3b-ff26-4d4d-9a62-a513e1c1bf92}',
'contract_ids': ['@mozilla.org/places/previews-helper;1'],
'jsm': 'resource://gre/modules/PlacesPreviews.jsm',
'esModule': 'resource://gre/modules/PlacesPreviews.sys.mjs',
'constructor': 'PlacesPreviewsHelperService',
},
]

Просмотреть файл

@ -58,20 +58,20 @@ if CONFIG["MOZ_PLACES"]:
]
EXTRA_JS_MODULES += [
"BookmarkHTMLUtils.jsm",
"BookmarkJSONUtils.jsm",
"Bookmarks.jsm",
"ExtensionSearchHandler.jsm",
"History.jsm",
"PlacesBackups.jsm",
"PlacesDBUtils.jsm",
"PlacesExpiration.jsm",
"PlacesPreviews.jsm",
"PlacesSyncUtils.jsm",
"PlacesTransactions.jsm",
"PlacesUtils.jsm",
"SyncedBookmarksMirror.jsm",
"TaggingService.jsm",
"BookmarkHTMLUtils.sys.mjs",
"BookmarkJSONUtils.sys.mjs",
"Bookmarks.sys.mjs",
"ExtensionSearchHandler.sys.mjs",
"History.sys.mjs",
"PlacesBackups.sys.mjs",
"PlacesDBUtils.sys.mjs",
"PlacesExpiration.sys.mjs",
"PlacesPreviews.sys.mjs",
"PlacesSyncUtils.sys.mjs",
"PlacesTransactions.sys.mjs",
"PlacesUtils.sys.mjs",
"SyncedBookmarksMirror.sys.mjs",
"TaggingService.sys.mjs",
]
XPCOM_MANIFESTS += [

Просмотреть файл

@ -1,7 +1,5 @@
"use strict";
var EXPORTED_SYMBOLS = ["PlacesTestUtils"];
const lazy = {};
ChromeUtils.defineModuleGetter(
lazy,
@ -14,7 +12,7 @@ ChromeUtils.defineModuleGetter(
"resource://testing-common/TestUtils.jsm"
);
var PlacesTestUtils = Object.freeze({
export var PlacesTestUtils = Object.freeze({
/**
* Asynchronously adds visits to a page.
*

Просмотреть файл

@ -7,7 +7,7 @@
TEST_DIRS += ["gtest"]
TESTING_JS_MODULES += [
"PlacesTestUtils.jsm",
"PlacesTestUtils.sys.mjs",
]
XPCSHELL_TESTS_MANIFESTS += [