Commit 828b9d73 authored by Carsten Schoenert's avatar Carsten Schoenert
Browse files

New upstream version 78.9.0

parent f5707a74
......@@ -4792,12 +4792,9 @@ checksum = "8eaa81235c7058867fa8c0e7314f33dcce9c215f535d1913822a2b3f5e289f3c"
[[package]]
name = "thin-vec"
version = "0.1.0"
version = "0.1.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "73fdf4b84c65a85168477b7fb6c498e0716bc9487fba24623389ea7f51708044"
dependencies = [
"libc",
]
checksum = "3a93c9ade36a827a69257925808463db46ffcf193442fad01eb9bdc1d31aed81"
[[package]]
name = "thiserror"
......
......@@ -67,7 +67,20 @@ Accessible* TableCellAccessible::PrevColHeader() {
// Check whether the previous table cell has a cached value.
cachedHeader = cache.GetWeak(tableCell, &inCache);
if (inCache && cell->Role() != roles::COLUMNHEADER) {
if (
// We check the cache first because even though we might not use it,
// it's faster than the other conditions.
inCache &&
// Only use the cached value if:
// 1. cell is a table cell which is not a column header. In that case,
// cell is the previous header and cachedHeader is the one before that.
// We will return cell later.
cell->Role() != roles::COLUMNHEADER &&
// 2. cell starts in this column. If it starts in a previous column and
// extends into this one, its header will be for the starting column,
// which is wrong for this cell.
// ColExtent is faster than ColIdx, so check that first.
(tableCell->ColExtent() == 1 || tableCell->ColIdx() == colIdx)) {
if (!cachedHeader || !cachedHeader->IsDefunct()) {
// Cache it for this cell.
cache.Put(this, RefPtr<Accessible>(cachedHeader));
......
......@@ -426,6 +426,37 @@
testHeaderCells(headerInfoMap);
// ////////////////////////////////////////////////////////////////////////
// Ensure correct column headers after colspan in a previous row.
headerInfoMap = [
{
cell: "t11r1c1",
columnHeaderCells: [],
rowHeaderCells: [],
},
{
cell: "t11r1c2",
columnHeaderCells: [],
rowHeaderCells: [],
},
{
cell: "t11r2c1_2",
columnHeaderCells: ["t11r1c1"],
rowHeaderCells: [],
},
{
cell: "t11r3c1",
columnHeaderCells: ["t11r1c1"],
rowHeaderCells: [],
},
{
cell: "t11r3c2",
columnHeaderCells: ["t11r1c2"],
rowHeaderCells: [],
},
];
testHeaderCells(headerInfoMap);
SimpleTest.finish();
}
......@@ -707,5 +738,19 @@
<td headers="t10_males t10_todd t10_10km" id="t10_r3c4">50:35</td>
</tr>
</table>
<table id="table11">
<tr>
<th id="t11r1c1">a</th>
<th id="t11r1c2">b</th>
</tr>
<tr>
<td id="t11r2c1_2" colspan="2"></td>
</tr>
<tr>
<td id="t11r3c1">e</td>
<td id="t11r3c2">f</td>
</tr>
</table>
</body>
</html>
......@@ -927,7 +927,7 @@
// XXX https://bugzilla.mozilla.org/show_bug.cgi?id=22183#c239
try {
if (docElement.getAttribute("chromehidden").includes("location")) {
const uri = Services.uriFixup.createExposableURI(aBrowser.currentURI);
const uri = Services.io.createExposableURI(aBrowser.currentURI);
let prefix = uri.prePath;
if (uri.scheme == "about") {
prefix = uri.spec;
......
......@@ -17,8 +17,28 @@ const TEST_PATH =
"http://example.net/browser/browser/" +
"components/resistfingerprinting/test/browser/";
var spoofedUserAgentNavigator;
var spoofedUserAgentHeader;
let expectedResults;
let osVersion = Services.sysinfo.get("version");
if (AppConstants.platform == "macosx") {
// Convert Darwin version to macOS version: 19.x.x -> 10.15 etc.
// https://en.wikipedia.org/wiki/Darwin_%28operating_system%29
let DarwinVersionParts = osVersion.split(".");
let DarwinMajorVersion = +DarwinVersionParts[0];
let macOsMinorVersion = DarwinMajorVersion - 4;
if (macOsMinorVersion > 15) {
macOsMinorVersion = 15;
}
osVersion = `10.${macOsMinorVersion}`;
}
const DEFAULT_APPVERSION = {
linux: "5.0 (X11)",
win: "5.0 (Windows)",
macosx: "5.0 (Macintosh)",
android: `5.0 (Android ${osVersion})`,
other: "5.0 (X11)",
};
const SPOOFED_APPNAME = "Netscape";
......@@ -29,6 +49,21 @@ const SPOOFED_APPVERSION = {
android: "5.0 (Android 9)",
other: "5.0 (X11)",
};
let cpuArch = Services.sysinfo.get("arch");
if (cpuArch == "x86-64") {
// Convert CPU arch "x86-64" to "x86_64" used in Linux and Android UAs.
cpuArch = "x86_64";
}
const DEFAULT_PLATFORM = {
linux: `Linux ${cpuArch}`,
win: "Win32",
macosx: "MacIntel",
android: `Linux ${cpuArch}`,
other: `Linux ${cpuArch}`,
};
const SPOOFED_PLATFORM = {
linux: "Linux x86_64",
win: "Win32",
......@@ -36,6 +71,20 @@ const SPOOFED_PLATFORM = {
android: "Linux aarch64",
other: "Linux x86_64",
};
const WindowsOscpu =
cpuArch == "x86_64"
? `Windows NT ${osVersion}; Win64; x64`
: `Windows NT ${osVersion}`;
const DEFAULT_OSCPU = {
linux: `Linux ${cpuArch}`,
win: WindowsOscpu,
macosx: `Intel Mac OS X ${osVersion}`,
android: `Linux ${cpuArch}`,
other: `Linux ${cpuArch}`,
};
const SPOOFED_OSCPU = {
linux: "Linux x86_64",
win: "Windows NT 10.0; Win64; x64",
......@@ -43,6 +92,15 @@ const SPOOFED_OSCPU = {
android: "Linux aarch64",
other: "Linux x86_64",
};
const DEFAULT_UA_OS = {
linux: `X11; Linux ${cpuArch}`,
win: WindowsOscpu,
macosx: `Macintosh; Intel Mac OS X ${osVersion}`,
android: `Android ${osVersion}; Mobile`,
other: `X11; Linux ${cpuArch}`,
};
const SPOOFED_UA_NAVIGATOR_OS = {
linux: "X11; Linux x86_64",
win: "Windows NT 10.0; Win64; x64",
......@@ -80,8 +138,8 @@ async function testUserAgentHeader() {
is(
result,
spoofedUserAgentHeader,
"User Agent HTTP Header is correctly spoofed."
expectedResults.userAgentHeader,
`Checking ${expectedResults.testDesc} User Agent HTTP Header.`
);
BrowserTestUtils.removeTab(tab);
......@@ -100,6 +158,8 @@ async function testNavigator() {
result = JSON.parse(result);
let testDesc = expectedResults.testDesc;
is(
result.appName,
SPOOFED_APPNAME,
......@@ -107,30 +167,28 @@ async function testNavigator() {
);
is(
result.appVersion,
SPOOFED_APPVERSION[AppConstants.platform],
"Navigator.appVersion is correctly spoofed."
expectedResults.appVersion,
`Checking ${testDesc} navigator.appVersion.`
);
is(
result.platform,
SPOOFED_PLATFORM[AppConstants.platform],
"Navigator.platform is correctly spoofed."
expectedResults.platform,
`Checking ${testDesc} navigator.platform.`
);
is(
result.userAgent,
spoofedUserAgentNavigator,
"Navigator.userAgent is correctly spoofed."
expectedResults.userAgentNavigator,
`Checking ${testDesc} navigator.userAgent.`
);
is(result.mimeTypesLength, 0, "Navigator.mimeTypes has a length of 0.");
is(result.pluginsLength, 0, "Navigator.plugins has a length of 0.");
is(
result.oscpu,
SPOOFED_OSCPU[AppConstants.platform],
"Navigator.oscpu is correctly spoofed."
expectedResults.oscpu,
`Checking ${testDesc} navigator.oscpu.`
);
is(
result.hardwareConcurrency,
SPOOFED_HW_CONCURRENCY,
"Navigator.hardwareConcurrency is correctly spoofed."
expectedResults.hardwareConcurrency,
`Checking ${testDesc} navigator.hardwareConcurrency.`
);
is(
......@@ -190,6 +248,8 @@ async function testWorkerNavigator() {
result = JSON.parse(result);
let testDesc = expectedResults.testDesc;
is(
result.appName,
SPOOFED_APPNAME,
......@@ -197,23 +257,23 @@ async function testWorkerNavigator() {
);
is(
result.appVersion,
SPOOFED_APPVERSION[AppConstants.platform],
"Navigator.appVersion is correctly spoofed."
expectedResults.appVersion,
`Checking ${testDesc} navigator.appVersion.`
);
is(
result.platform,
SPOOFED_PLATFORM[AppConstants.platform],
"Navigator.platform is correctly spoofed."
expectedResults.platform,
`Checking ${testDesc} navigator.platform.`
);
is(
result.userAgent,
spoofedUserAgentNavigator,
"Navigator.userAgent is correctly spoofed."
expectedResults.userAgentNavigator,
`Checking ${testDesc} navigator.userAgent.`
);
is(
result.hardwareConcurrency,
SPOOFED_HW_CONCURRENCY,
"Navigator.hardwareConcurrency is correctly spoofed."
expectedResults.hardwareConcurrency,
`Checking ${testDesc} navigator.hardwareConcurrency.`
);
is(
......@@ -244,7 +304,35 @@ async function testWorkerNavigator() {
}
}
add_task(async function setup() {
add_task(async function setupDefaultUserAgent() {
let appVersion = parseInt(Services.appinfo.version);
let defaultUserAgent = `Mozilla/5.0 (${
DEFAULT_UA_OS[AppConstants.platform]
}; rv:${appVersion}.0) Gecko/20100101 Firefox/${appVersion}.0`;
expectedResults = {
testDesc: "default",
appVersion: DEFAULT_APPVERSION[AppConstants.platform],
hardwareConcurrency: navigator.hardwareConcurrency,
oscpu: DEFAULT_OSCPU[AppConstants.platform],
platform: DEFAULT_PLATFORM[AppConstants.platform],
userAgentNavigator: defaultUserAgent,
userAgentHeader: defaultUserAgent,
};
});
add_task(async function runDefaultNavigatorTest() {
await testNavigator();
});
add_task(async function runDefaultHTTPHeaderTest() {
await testUserAgentHeader();
});
add_task(async function runDefaultWorkerNavigatorTest() {
await testWorkerNavigator();
});
add_task(async function setupResistFingerprinting() {
await SpecialPowers.pushPrefEnv({
set: [["privacy.resistFingerprinting", true]],
});
......@@ -252,24 +340,34 @@ add_task(async function setup() {
let appVersion = parseInt(Services.appinfo.version);
let spoofedVersion = appVersion - ((appVersion - 78) % 13);
spoofedUserAgentNavigator = `Mozilla/5.0 (${
let spoofedUserAgentNavigator = `Mozilla/5.0 (${
SPOOFED_UA_NAVIGATOR_OS[AppConstants.platform]
}; rv:${spoofedVersion}.0) Gecko/20100101 Firefox/${spoofedVersion}.0`;
spoofedUserAgentHeader = `Mozilla/5.0 (${
let spoofedUserAgentHeader = `Mozilla/5.0 (${
SPOOFED_UA_HTTPHEADER_OS[AppConstants.platform]
}; rv:${spoofedVersion}.0) Gecko/20100101 Firefox/${spoofedVersion}.0`;
expectedResults = {
testDesc: "spoofed",
appVersion: SPOOFED_APPVERSION[AppConstants.platform],
hardwareConcurrency: SPOOFED_HW_CONCURRENCY,
oscpu: SPOOFED_OSCPU[AppConstants.platform],
platform: SPOOFED_PLATFORM[AppConstants.platform],
userAgentNavigator: spoofedUserAgentNavigator,
userAgentHeader: spoofedUserAgentHeader,
};
});
add_task(async function runNavigatorTest() {
add_task(async function runSpoofedNavigatorTest() {
await testNavigator();
});
add_task(async function runHTTPHeaderTest() {
add_task(async function runSpoofedHTTPHeaderTest() {
await testUserAgentHeader();
});
add_task(async function runWorkerNavigatorTest() {
add_task(async function runSpoofedWorkerNavigatorTest() {
await testWorkerNavigator();
});
......
......@@ -2,7 +2,7 @@
"name": "Allegro",
"description": "Wyszukiwanie w aukcjach Allegro",
"manifest_version": 2,
"version": "1.0",
"version": "1.1",
"applications": {
"gecko": {
"id": "allegro-pl@search.mozilla.org"
......@@ -18,9 +18,9 @@
"chrome_settings_overrides": {
"search_provider": {
"name": "Allegro",
"search_url": "https://allegro.pl/listing/listing.php",
"search_url": "https://allegro.pl/listing",
"search_form": "https://allegro.pl",
"search_url_get_params": "string={searchTerms}&sourceid=Mozilla-search"
}
}
}
\ No newline at end of file
}
......@@ -137,8 +137,9 @@ with only_when(host_is_osx | target_is_osx):
help='Location of platform SDK to use')
@depends('--with-macos-sdk', host)
@imports(_from='__builtin__', _import='open')
@imports(_from='os.path', _import='isdir')
@imports(_from='biplist', _import='readPlist')
@imports('plistlib')
def macos_sdk(sdk, host):
sdk_min_version = Version('10.11')
sdk_max_version = Version('10.15.4')
......@@ -159,7 +160,8 @@ with only_when(host_is_osx | target_is_osx):
'valid SDK. SDKs are installed when the optional cross-development '
'tools are selected during the Xcode/Developer Tools installation.'
% sdk)
obj = readPlist(os.path.join(sdk, 'SDKSettings.plist'))
with open(os.path.join(sdk, 'SDKSettings.plist'), 'rb') as plist:
obj = plistlib.load(plist)
if not obj:
die('Error parsing SDKSettings.plist in the SDK directory: %s' % sdk)
if 'Version' not in obj:
......
---
GECKO_BASE_REPOSITORY: https://hg.mozilla.org/mozilla-unified
GECKO_HEAD_REPOSITORY: https://hg.mozilla.org/releases/mozilla-esr78
GECKO_HEAD_REF: FIREFOX_78_8_0esr_BUILD2
GECKO_HEAD_REV: f35972ee2800dd61e7994a3340b721df8887f8bd
GECKO_HEAD_REF: FIREFOX_78_9_0esr_BUILD1
GECKO_HEAD_REV: 403985a1dd4d3c4c51ab977e1212bef4bfee6a32
### For comm-central
# GECKO_BASE_REPOSITORY: https://hg.mozilla.org/mozilla-unified
......
......@@ -489,13 +489,11 @@
this.setAttribute("type", this.type);
this.addEventListener(
"viewresize",
event => {
this.onResize(this);
},
true
);
window.addEventListener("viewresize", event => {
if (this.isVisible()) {
this.onResize();
}
});
// Add a preference observer to monitor changes.
Services.prefs.addObserver("calendar.", this.mPrefObserver);
......@@ -529,7 +527,7 @@
*
* @param {calICalendarView} [calViewElem] - A calendar view element.
*/
onResize(calView) {
onResize() {
// Child classes should provide the implementation.
throw new Error(this.constructor.name + ".onResize not implemented");
}
......
......@@ -76,10 +76,13 @@ async function loadCalendarComponent() {
// Start alarm service
Cc["@mozilla.org/calendar/alarm-service;1"].getService(Ci.calIAlarmService).startup();
document.getElementById("calsidebar_splitter").addEventListener("command", () => {
document.dispatchEvent(new CustomEvent("viewresize", { bubbles: true }));
window.dispatchEvent(new CustomEvent("viewresize"));
});
document.getElementById("calendar-view-splitter").addEventListener("command", () => {
window.dispatchEvent(new CustomEvent("viewresize"));
});
window.addEventListener("resize", () => {
document.dispatchEvent(new CustomEvent("viewresize", { bubbles: true }));
window.dispatchEvent(new CustomEvent("viewresize"));
});
// Set calendar color CSS on this window
......
......@@ -446,23 +446,12 @@ function loadCalendarManager() {
QueryInterface: ChromeUtils.generateQI([Ci.calICalendarManagerObserver]),
onCalendarRegistered(calendar) {
let inComposite = calendar.getProperty("calendar-main-in-composite");
if (inComposite === null && !calendar.getProperty("disabled")) {
compositeCalendar.addCalendar(calendar);
}
addCalendarItem(calendar);
saveSortOrder();
},
onCalendarUnregistering(calendar) {
compositeCalendar.removeCalendar(calendar);
let item = calendarList.getElementsByAttribute("calendar-id", calendar.id)[0];
item.remove();
if (
!compositeCalendar.defaultCalendar ||
compositeCalendar.defaultCalendar.id == calendar.id
) {
compositeCalendar.defaultCalendar = compositeCalendar.getCalendars()[0];
}
saveSortOrder();
},
onCalendarDeleting(calendar) {},
......
......@@ -93,7 +93,7 @@ function calSwitchToCalendarMode() {
window.setCursor("auto");
// make sure the view is sized correctly
document.dispatchEvent(new CustomEvent("viewresize", { bubbles: true }));
window.dispatchEvent(new CustomEvent("viewresize"));
// Load the unifinder if it isn't already loaded.
ensureUnifinderLoaded();
......
......@@ -385,8 +385,8 @@ var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
*
* @param {Element} viewElement A calendar view element (calICalendarView).
*/
onResize(viewElement) {
viewElement.adjustWeekdayLength();
onResize() {
this.adjustWeekdayLength();
// Delete the timer for the time indicator in day/week view.
timeIndicator.cancel();
}
......
......@@ -670,36 +670,33 @@
*
* @param {Element} calViewElem A calendar view element (calICalendarView).
*/
onResize(calViewElem) {
const self = calViewElem || this; // eslint-disable-line consistent-this
const isARelayout = !calViewElem;
onResize() {
const scrollboxRect = this.scrollbox.getBoundingClientRect();
const isOrientHorizontal = self.getAttribute("orient") == "horizontal";
const isOrientHorizontal = this.getAttribute("orient") == "horizontal";
const size = isOrientHorizontal ? scrollboxRect.width : scrollboxRect.height;
const ppmRaw = size / self.mVisibleMinutes;
const ppmRaw = size / this.mVisibleMinutes;
const ppmRounded = Math.floor(ppmRaw * 1000) / 1000;
const ppm = ppmRounded < self.mMinPixelsPerMinute ? self.mMinPixelsPerMinute : ppmRounded;
const ppm = ppmRounded < this.mMinPixelsPerMinute ? this.mMinPixelsPerMinute : ppmRounded;
const ppmHasChanged = self.pixelsPerMinute != ppm;
self.pixelsPerMinute = ppm;
const ppmHasChanged = this.pixelsPerMinute != ppm;
this.pixelsPerMinute = ppm;
setTimeout(() => self.scrollToMinute(self.mFirstVisibleMinute), 0);
setTimeout(() => this.scrollToMinute(this.mFirstVisibleMinute), 0);
// Fit the weekday labels while scrolling.
self.adjustWeekdayLength(isOrientHorizontal);
this.adjustWeekdayLength(isOrientHorizontal);
// Adjust the time indicator position and the related timer.
if (this.mTimeIndicatorInterval != 0) {
const viewHasChanged = isARelayout && timeIndicator.lastView != this.id;
const viewHasChanged = timeIndicator.lastView != this.id;
if (
gCurrentMode == "calendar" &&
(!timeIndicator.timer || ppmHasChanged || viewHasChanged)
) {
self.updateTimeIndicatorPosition(true, ppmHasChanged, viewHasChanged);
this.updateTimeIndicatorPosition(true, ppmHasChanged, viewHasChanged);
}
}
}
......
......@@ -981,6 +981,7 @@ function toggleUnifinder() {
// Toggle the elements
goToggleToolbar("bottom-events-box", "calendar_show_unifinder_command");
goToggleToolbar("calendar-view-splitter");
window.dispatchEvent(new CustomEvent("viewresize"));
unifinderTreeView.treeElement.view = unifinderTreeView;