[tor-commits] [Git][tpo/applications/tor-browser][tor-browser-115.1.0esr-13.0-1] amend! Bug 32308: use direct browser sizing for letterboxing.
ma1 (@ma1)
git at gitlab.torproject.org
Tue Aug 8 07:08:35 UTC 2023
ma1 pushed to branch tor-browser-115.1.0esr-13.0-1 at The Tor Project / Applications / Tor Browser
Commits:
63eecb92 by hackademix at 2023-08-08T08:08:43+02:00
amend! Bug 32308: use direct browser sizing for letterboxing.
Bug 32308: use direct browser sizing for letterboxing.
Bug 30556: align letterboxing with 200x100 new win width stepping
- - - - -
1 changed file:
- toolkit/components/resistfingerprinting/RFPHelper.sys.mjs
Changes:
=====================================
toolkit/components/resistfingerprinting/RFPHelper.sys.mjs
=====================================
@@ -475,14 +475,14 @@ class _RFPHelper {
/**
* Given a width or height, rounds it with the proper stepping.
*/
- steppedSize(aDimension) {
+ steppedSize(aDimension, isWidth = false) {
let stepping;
if (aDimension <= 50) {
return 0;
} else if (aDimension <= 500) {
stepping = 50;
} else if (aDimension <= 1600) {
- stepping = 100;
+ stepping = isWidth ? 200 : 100;
} else {
stepping = 200;
}
@@ -569,7 +569,7 @@ class _RFPHelper {
// If the set is empty, we will round the content with the default
// stepping size.
if (!this._letterboxingDimensions.length) {
- result = r(this.steppedSize(aWidth), this.steppedSize(aHeight));
+ result = r(this.steppedSize(aWidth, true), this.steppedSize(aHeight));
log(
`${logPrefix} roundDimensions(${aWidth}, ${aHeight}) = ${result.width} x ${result.height}`
);
View it on GitLab: https://gitlab.torproject.org/tpo/applications/tor-browser/-/commit/63eecb9243e5fb0af6fb158e1abd93aaaab8be32
--
View it on GitLab: https://gitlab.torproject.org/tpo/applications/tor-browser/-/commit/63eecb9243e5fb0af6fb158e1abd93aaaab8be32
You're receiving this email because of your account on gitlab.torproject.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.torproject.org/pipermail/tor-commits/attachments/20230808/8c07bab9/attachment-0001.htm>
More information about the tor-commits
mailing list