mirror of
https://github.com/zen-browser/desktop.git
synced 2026-08-22 14:40:50 +00:00
chore: Sync upstream to Firefox 149.0
This commit is contained in:
committed by
github-actions[bot]
parent
9bd76d3ad0
commit
820d795bd1
@@ -35,7 +35,7 @@ Zen is a firefox-based browser with the aim of pushing your productivity to a ne
|
||||
### Firefox Versions
|
||||
|
||||
- [`Release`](https://zen-browser.app/download) - Is currently built using Firefox version `148.0.2`! 🚀
|
||||
- [`Twilight`](https://zen-browser.app/download?twilight) - Is currently built using Firefox version `RC 148.0.2`!
|
||||
- [`Twilight`](https://zen-browser.app/download?twilight) - Is currently built using Firefox version `RC 149.0`!
|
||||
|
||||
### Contributing
|
||||
|
||||
|
||||
@@ -1 +1 @@
|
||||
7b8f3620beb1de157d972de32f9f34320f0ae189
|
||||
c10d7dc50d4b596942cce48f8b023b831a27480a
|
||||
@@ -3,7 +3,6 @@
|
||||
[DEFAULT]
|
||||
skip-if = [
|
||||
"ccov",
|
||||
"os == 'linux' && os_version == '22.04' && arch == 'x86_64' && display == 'wayland' && asan", # bug 1784517
|
||||
"os == 'linux' && os_version == '24.04' && arch == 'x86_64' && display == 'x11' && asan", # bug 1784517
|
||||
"os == 'linux' && os_version == '24.04' && arch == 'x86_64' && display == 'x11' && tsan", # bug 1784517
|
||||
]
|
||||
@@ -22,4 +21,6 @@ environment = [
|
||||
profile-path = "/tmp/.xdg_default_test/.config/mozilla/firefox/xdg_default_profile"
|
||||
|
||||
["browser_content_sandbox_fs_xdg_default.js"]
|
||||
run-if = ["os == 'linux'"]
|
||||
run-if = [
|
||||
"os == 'linux'"
|
||||
]
|
||||
|
||||
@@ -3,7 +3,6 @@
|
||||
[DEFAULT]
|
||||
skip-if = [
|
||||
"ccov",
|
||||
"os == 'linux' && os_version == '22.04' && arch == 'x86_64' && display == 'wayland' && asan", # bug 1784517
|
||||
"os == 'linux' && os_version == '24.04' && arch == 'x86_64' && display == 'x11' && asan", # bug 1784517
|
||||
"os == 'linux' && os_version == '24.04' && arch == 'x86_64' && display == 'x11' && tsan", # bug 1784517
|
||||
]
|
||||
@@ -25,4 +24,6 @@ environment = [
|
||||
profile-path = "/tmp/.xdg_mozLegacyHome_test/.mozilla/firefox/xdg_mozLegacyHome_profile"
|
||||
|
||||
["browser_content_sandbox_fs_xdg_mozLegacyHome.js"]
|
||||
run-if = ["os == 'linux'"]
|
||||
run-if = [
|
||||
"os == 'linux'"
|
||||
]
|
||||
|
||||
@@ -0,0 +1,72 @@
|
||||
/* Any copyright is dedicated to the Public Domain.
|
||||
* https://creativecommons.org/publicdomain/zero/1.0/ */
|
||||
|
||||
"use strict";
|
||||
|
||||
ChromeUtils.defineESModuleGetters(this, {
|
||||
FileTestUtils: "resource://testing-common/FileTestUtils.sys.mjs",
|
||||
ShellService: "moz-src:///browser/components/shell/ShellService.sys.mjs",
|
||||
XPCOMUtils: "resource://gre/modules/XPCOMUtils.sys.mjs",
|
||||
});
|
||||
|
||||
XPCOMUtils.defineLazyServiceGetters(this, {
|
||||
imgTools: ["@mozilla.org/image/tools;1", Ci.imgITools],
|
||||
});
|
||||
|
||||
let gPngImage;
|
||||
let gSvgImage;
|
||||
|
||||
add_setup(async function loadImages() {
|
||||
let pngFile = do_get_file("favicon-normal16.png");
|
||||
gPngImage = imgTools.decodeImageFromArrayBuffer(
|
||||
(await IOUtils.read(pngFile.path)).buffer,
|
||||
"image/png"
|
||||
);
|
||||
|
||||
let svgFile = do_get_file("icon.svg");
|
||||
let svgUri = Services.io.newFileURI(svgFile);
|
||||
let svgChannel = Services.io.newChannelFromURI(
|
||||
svgUri,
|
||||
null,
|
||||
Services.scriptSecurityManager.getSystemPrincipal(),
|
||||
null,
|
||||
Ci.nsILoadInfo.SEC_ALLOW_CROSS_ORIGIN_SEC_CONTEXT_IS_NULL,
|
||||
Ci.nsIContentPolicy.TYPE_IMAGE
|
||||
);
|
||||
gSvgImage = await ChromeUtils.fetchDecodedImage(svgUri, svgChannel);
|
||||
});
|
||||
|
||||
/**
|
||||
* Ensures that the file is an ICO file with the correct dimensions.
|
||||
*
|
||||
* Currently, this doesn't actually check the file's image data, since that's
|
||||
* (a) difficult to do from JavaScript for raster files (especially given the
|
||||
* scaling) and (b) not easy in general for vector files without just rewriting
|
||||
* createWindowsIcon inline.
|
||||
*
|
||||
* @param {nsIFile} file - The file containing the image.
|
||||
*/
|
||||
async function verifyOutput(file) {
|
||||
let image = imgTools.decodeImageFromArrayBuffer(
|
||||
(await IOUtils.read(file.path)).buffer,
|
||||
"image/vnd.microsoft.icon"
|
||||
);
|
||||
|
||||
ok(image, "Image decoded successfully from its native format");
|
||||
Assert.equal(image.width, 256, "Image is 256 pixels wide");
|
||||
Assert.equal(image.height, 256, "Image is 256 pixels tall");
|
||||
}
|
||||
|
||||
add_task(async function test_iconDimensions_raster() {
|
||||
let tempFile = FileTestUtils.getTempFile();
|
||||
await ShellService.createWindowsIcon(tempFile, gPngImage);
|
||||
await verifyOutput(tempFile);
|
||||
await IOUtils.remove(tempFile.path);
|
||||
});
|
||||
|
||||
add_task(async function test_iconDimensions_vector() {
|
||||
let tempFile = FileTestUtils.getTempFile();
|
||||
await ShellService.createWindowsIcon(tempFile, gSvgImage);
|
||||
await verifyOutput(tempFile);
|
||||
await IOUtils.remove(tempFile.path);
|
||||
});
|
||||
@@ -9,3 +9,12 @@ tags = "os_integration"
|
||||
run-if = [
|
||||
"os == 'mac'",
|
||||
]
|
||||
|
||||
["test_writeShortcutIcon.js"]
|
||||
run-if = [
|
||||
"os == 'win'",
|
||||
]
|
||||
support-files = [
|
||||
"../../../places/tests/browser/favicon-normal16.png",
|
||||
"../../../../base/content/test/favicons/icon.svg",
|
||||
]
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
"version": {
|
||||
"product": "firefox",
|
||||
"version": "148.0.2",
|
||||
"candidate": "148.0.2",
|
||||
"candidate": "149.0",
|
||||
"candidateBuild": 1
|
||||
},
|
||||
"buildOptions": {
|
||||
|
||||
Reference in New Issue
Block a user