mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-30 16:22:00 +00:00
Bug 1795462 - Importing data from OperaGX. r=mconley,fluent-reviewers,flod.
Differential Revision: https://phabricator.services.mozilla.com/D160868
This commit is contained in:
parent
8001c448d1
commit
ecdb912abf
@ -2145,6 +2145,7 @@ pref("browser.migrate.ie.enabled", true);
|
||||
pref("browser.migrate.safari.enabled", true);
|
||||
pref("browser.migrate.opera.enabled", false);
|
||||
pref("browser.migrate.vivaldi.enabled", false);
|
||||
pref("browser.migrate.opera-gx.enabled", false);
|
||||
|
||||
pref("browser.migrate.content-modal.enabled", false);
|
||||
|
||||
|
@ -268,6 +268,7 @@ export var ChromeMigrationUtils = {
|
||||
"Edge Beta": ["Microsoft", "Edge Beta"],
|
||||
"360 SE": ["360se6"],
|
||||
Opera: ["Opera Software", "Opera Stable"],
|
||||
"Opera GX": ["Opera Software", "Opera GX Stable"],
|
||||
Vivaldi: ["Vivaldi"],
|
||||
},
|
||||
macosx: {
|
||||
@ -277,6 +278,7 @@ export var ChromeMigrationUtils = {
|
||||
Canary: ["Google", "Chrome Canary"],
|
||||
Edge: ["Microsoft Edge"],
|
||||
"Edge Beta": ["Microsoft Edge Beta"],
|
||||
"Opera GX": ["com.operasoftware.OperaGX"],
|
||||
Opera: ["com.operasoftware.Opera"],
|
||||
Vivaldi: ["Vivaldi"],
|
||||
},
|
||||
@ -286,6 +288,7 @@ export var ChromeMigrationUtils = {
|
||||
"Chrome Beta": ["google-chrome-beta"],
|
||||
"Chrome Dev": ["google-chrome-unstable"],
|
||||
Chromium: ["chromium"],
|
||||
"Opera GX": ["Opera-GX"],
|
||||
// Canary is not available on Linux.
|
||||
// Edge is not available on Linux.
|
||||
Opera: ["Opera"],
|
||||
@ -299,12 +302,16 @@ export var ChromeMigrationUtils = {
|
||||
|
||||
let rootDir;
|
||||
if (AppConstants.platform == "win") {
|
||||
if (chromeProjectName === "360 SE" || chromeProjectName === "Opera") {
|
||||
if (
|
||||
chromeProjectName === "360 SE" ||
|
||||
chromeProjectName === "Opera" ||
|
||||
chromeProjectName === "Opera GX"
|
||||
) {
|
||||
rootDir = "AppData";
|
||||
} else {
|
||||
rootDir = "LocalAppData";
|
||||
}
|
||||
if (chromeProjectName != "Opera") {
|
||||
if (chromeProjectName != "Opera" && chromeProjectName != "Opera GX") {
|
||||
subfolders = subfolders.concat(["User Data"]);
|
||||
}
|
||||
} else if (AppConstants.platform == "macosx") {
|
||||
|
@ -750,6 +750,24 @@ OperaProfileMigrator.prototype.getSourceProfiles = function() {
|
||||
return null;
|
||||
};
|
||||
|
||||
export function OperaGXProfileMigrator() {
|
||||
this._chromeUserDataPathSuffix = "Opera GX";
|
||||
this._keychainServiceName = "Opera Browser Safe Storage";
|
||||
this._keychainAccountName = "Opera Browser";
|
||||
}
|
||||
OperaGXProfileMigrator.prototype = Object.create(
|
||||
ChromeProfileMigrator.prototype
|
||||
);
|
||||
OperaGXProfileMigrator.prototype.classDescription = "Opera GX Browser Migrator";
|
||||
OperaGXProfileMigrator.prototype.contractID =
|
||||
"@mozilla.org/profile/migrator;1?app=browser&type=opera-gx";
|
||||
OperaGXProfileMigrator.prototype.classID = Components.ID(
|
||||
"{26F4E0A0-B533-4FDA-B344-6FF5DA45D6DC}"
|
||||
);
|
||||
OperaGXProfileMigrator.prototype.getSourceProfiles = function() {
|
||||
return null;
|
||||
};
|
||||
|
||||
export function VivaldiProfileMigrator() {
|
||||
this._chromeUserDataPathSuffix = "Vivaldi";
|
||||
this._keychainServiceName = "Vivaldi Safe Storage";
|
||||
|
@ -44,6 +44,7 @@ const gAvailableMigratorKeys = (function() {
|
||||
"edge",
|
||||
"ie",
|
||||
"opera",
|
||||
"opera-gx",
|
||||
"vivaldi",
|
||||
"brave",
|
||||
"chrome",
|
||||
@ -60,6 +61,7 @@ const gAvailableMigratorKeys = (function() {
|
||||
"firefox",
|
||||
"safari",
|
||||
"opera",
|
||||
"opera-gx",
|
||||
"vivaldi",
|
||||
"brave",
|
||||
"chrome",
|
||||
@ -79,6 +81,7 @@ const gAvailableMigratorKeys = (function() {
|
||||
"chrome-beta",
|
||||
"chrome-dev",
|
||||
"chromium",
|
||||
"opera-gx",
|
||||
];
|
||||
}
|
||||
return [];
|
||||
@ -746,6 +749,7 @@ export var MigrationUtils = Object.seal({
|
||||
Nightly: "firefox",
|
||||
Opera: "opera",
|
||||
Vivaldi: "vivaldi",
|
||||
"Opera GX": "opera-gx",
|
||||
"Brave Web Browser": "brave", // Windows, Linux
|
||||
Brave: "brave", // OS X
|
||||
"Google Chrome": "chrome", // Windows, Linux
|
||||
@ -1294,6 +1298,7 @@ export var MigrationUtils = Object.seal({
|
||||
"chromium-edge-beta": 10,
|
||||
brave: 11,
|
||||
opera: 12,
|
||||
"opera-gx": 14,
|
||||
vivaldi: 13,
|
||||
},
|
||||
getSourceIdForTelemetry(sourceName) {
|
||||
|
@ -44,6 +44,12 @@ Classes = [
|
||||
'esModule': 'resource:///modules/FirefoxProfileMigrator.sys.mjs',
|
||||
'constructor': 'FirefoxProfileMigrator',
|
||||
},
|
||||
{
|
||||
'cid': '{26F4E0A0-B533-4FDA-B344-6FF5DA45D6DC}',
|
||||
'contract_ids': ['@mozilla.org/profile/migrator;1?app=browser&type=opera-gx'],
|
||||
'esModule': 'resource:///modules/ChromeProfileMigrator.sys.mjs',
|
||||
'constructor': 'OperaGXProfileMigrator',
|
||||
},
|
||||
{
|
||||
'cid': '{54a6a025-e70d-49dd-ba95-0f7e45d728d3}',
|
||||
'contract_ids': ['@mozilla.org/profile/migrator;1?app=browser&type=vivaldi'],
|
||||
|
@ -45,6 +45,7 @@
|
||||
<radio id="canary" data-l10n-id="import-from-canary" />
|
||||
<radio id="vivaldi" data-l10n-id="import-from-vivaldi"/>
|
||||
<radio id="chromium-360se" data-l10n-id="import-from-360se"/>
|
||||
<radio id="opera-gx" data-l10n-id="import-from-opera-gx"/>
|
||||
#elifdef XP_MACOSX
|
||||
<radio id="safari" data-l10n-id="import-from-safari"/>
|
||||
<radio id="opera" data-l10n-id="import-from-opera"/>
|
||||
@ -55,6 +56,7 @@
|
||||
<radio id="chromium" data-l10n-id="import-from-chromium"/>
|
||||
<radio id="canary" data-l10n-id="import-from-canary"/>
|
||||
<radio id="vivaldi" data-l10n-id="import-from-vivaldi"/>
|
||||
<radio id="opera-gx" data-l10n-id="import-from-opera-gx"/>
|
||||
#elifdef XP_UNIX
|
||||
<radio id="opera" data-l10n-id="import-from-opera"/>
|
||||
<radio id="vivaldi" data-l10n-id="import-from-vivaldi"/>
|
||||
@ -63,6 +65,7 @@
|
||||
<radio id="chrome-beta" data-l10n-id="import-from-chrome-beta"/>
|
||||
<radio id="chrome-dev" data-l10n-id="import-from-chrome-dev"/>
|
||||
<radio id="chromium" data-l10n-id="import-from-chromium"/>
|
||||
<radio id="opera-gx" data-l10n-id="import-from-opera-gx"/>
|
||||
#endif
|
||||
<radio id="nothing" data-l10n-id="import-from-nothing" hidden="true"/>
|
||||
</radiogroup>
|
||||
|
@ -60,6 +60,9 @@ import-from-firefox =
|
||||
import-from-360se =
|
||||
.label = 360 Secure Browser
|
||||
.accesskey = 3
|
||||
import-from-opera-gx =
|
||||
.label = Opera GX
|
||||
.accesskey = G
|
||||
|
||||
no-migration-sources = No programs that contain bookmarks, history or password data could be found.
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user