I’m wondering if there’s a way to dynamically set the display size / pixel ratio in an extension. The end goal is to allow https://open.spotify.com/ to work on Firefox Android in Desktop Mode such that it is possible to access the user’s song library. I’m able to do so currently on Android Nightly by setting layout.css.devPixelsPerPx
in about:config
to a value (e.g. 3) such that the display resolution is sufficiently large. A resolution of 480x853 in Desktop Mode is sufficient to allow full user access to the library and basically functions the same as the using spotify on desktop. My normal resolution of 360x640 is too low.
Ideally I would like to set the resolution only when the visiting open.spotify.com. I don’t believe changing the about:config
settings is possible via an extension. It looks like Chrome has system.display
[1] which allows setting deviceScaleFactor
via DisplayMode
object (though I’ve not tried). I don’t see this in Firefox however.
Is there a way to do this in Firefox?
References:
[1] https://developer.chrome.com/docs/extensions/reference/system_display/#method-setDisplayProperties