desktop: randomize screen+available screen based on inner
https://bugzilla.mozilla.org/show_bug.cgi?id=1591337
desktop only
I will refer to screen + available screen as SCREEN. These are always the same to hide docker/taskbar measurements I will refer to inner + outer as WINDOW. These are always the same to hide chrome measurements
This proposal is to handle SCREEN differently from WINDOW, but still base it on WINDOW. This allows us to reduce SCREEN buckets
current:
- all four (inner, outer, screen, available screen) = tied to inner
- this means the possible resolutions for SCREEN are affected by the user and newin (+LB), and even worse if the user has disabled LBing (accidental resizes are not hard to do with a windowed object)
- the possible buckets are either our LBing stepping or almost every combo without LBing
- even in a perfect world, we still have entropy in SCREEN because newwin sizes vary (8 or 9 buckets?)
new:
- inner is not exactly a stable metric - users resize, snap to edges in tile managers, toggle chrome bits, zoom, etc (I am excluding full screen). So at worst at least some scripts are highly likely IMO to discard this as a linkability factor since the IP is different. It's just not a good metric. Screen is a much more stable metric
- WINDOW = newwin + LB sizes
- SCREEN = step it based on WINDOW
- by still being tied to inner, this means entropy mathematically cannot be increased, but it will be decreased in scripts that rely only screen
- we step on width AND height, i.e try to make the inner res fit the screen res, but if we can't, no big deal (see below)
- we can use 4 or 5 common screen sizes, e.g. 2k, 3k, 4k (maybe 8k)
- the common sizes could really be anything we want, but we can choose common ones if it makes it seem more natural/real
- it doesn't matter if SCREEN ends up making the inner look weird, e.g partially offscreen due to physical rotation to portrait, or if the screen is actually bigger than our max values because we're lying, who cares - did anyone seriously believe our figures before? Did anyone really believe inner has always equaled outer? We lie, bug deal :)
- full screen is an issue with or without this change and is a different problem
- note/bonus: it will upset scripts that use screen = inner logic as a point of difference to detect TB in JS (and making that harder is always fun)
orientation (matchmedia/css)
- since screen width + height always match our array of 3 or 4 common landscape resolutions (this is desktop), then we need to also make sure that orientation is hooked into this (or just always report landscape to save some perf)
- I think there's currently an RFP orientation patch (really old) which kinda doesn't make sense?. By always being landscape the new RFP orientation patch would make sense
As per earlier discussion to "scream" about this louder @tom @richard