author | Trishul <trishul.goel@gmail.com> |
Fri, 29 Mar 2019 20:44:42 +0000 | |
changeset 466841 | 92cfc564dbffe32ed1a6501bdddd8e8ea9bdf604 |
parent 466840 | c6b7f090b90ac0616e46e82e14af60a9cf3b186d |
child 466842 | 6adc2a2a4988785c5d69a51f7746cef0bb46b57b |
push id | 35784 |
push user | nerli@mozilla.com |
push date | Sat, 30 Mar 2019 09:32:04 +0000 |
treeherder | mozilla-central@d42c60ccf0d0 [default view] [failures only] |
perfherder | [talos] [build metrics] [platform microbench] (compared to previous push) |
reviewers | kmag |
bugs | 1538583 |
milestone | 68.0a1 |
first release with | nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
|
last release without | nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
|
--- a/toolkit/mozapps/extensions/content/extensions.xml +++ b/toolkit/mozapps/extensions/content/extensions.xml @@ -898,17 +898,17 @@ this.setAttribute("previewURL", previewURL ? previewURL : ""); this.setAttribute("hasPreview", previewURL ? "true" : "fase"); let legacyWarning = legacyExtensionsEnabled && !this.mAddon.install && isLegacyExtension(this.mAddon); this.setAttribute("legacy", legacyWarning); document.getAnonymousElementByAttribute(this, "anonid", "legacy").href = SUPPORT_URL + "webextensions"; - if (!allowPrivateBrowsingByDefault) { + if (!allowPrivateBrowsingByDefault && this.mAddon.type === "extension") { ExtensionPermissions.get(this.mAddon.id).then((perms) => { let allowed = perms.permissions.includes("internal:privateBrowsingAllowed"); this.setAttribute("privateBrowsing", allowed); if (!allowed && PrivateBrowsingUtils.isContentWindowPrivate(window)) { // Hide the preferences button if the current window is // private and the addon is not allowed to access it. this._preferencesBtn.hidden = true; }
--- a/toolkit/mozapps/extensions/test/browser/browser_theme_previews.js +++ b/toolkit/mozapps/extensions/test/browser/browser_theme_previews.js @@ -130,13 +130,19 @@ add_task(async function testThemeOrderin idOrder, [ themeId(8), // The active theme first. themeId(6), themeId(7), // With previews, ordered by name. themeId(5), // The theme without a preview last. ], "Themes are ordered by enabled, previews, then name"); + // Ensure allow in private mode badge is hidden for themes. + for (let item of list.itemChildren) { + let badge = gManagerWindow.document.getAnonymousElementByAttribute(item, "anonid", "privateBrowsing"); + is_element_hidden(badge, `private browsing badge is hidden`); + } + await close_manager(gManagerWindow); for (let addon of await promiseAddonsByIDs(themeIds)) { await addon.uninstall(); } });