White space between address bar and viewport in Samsung DeX
Categories
(Firefox for Android :: Toolbar, defect)
Tracking
()
People
(Reporter: XXLPoseidon, Unassigned)
Details
Attachments
(16 files)
|
394.55 KB,
image/png
|
Details | |
|
485.49 KB,
image/png
|
Details | |
|
111.18 KB,
image/png
|
Details | |
|
258.05 KB,
image/png
|
Details | |
|
195.92 KB,
image/png
|
Details | |
|
65.08 KB,
image/png
|
Details | |
|
70.50 KB,
image/png
|
Details | |
|
80.70 KB,
image/png
|
Details | |
|
97.99 KB,
image/png
|
Details | |
|
74.56 KB,
image/png
|
Details | |
|
108.86 KB,
image/png
|
Details | |
|
63.09 KB,
image/png
|
Details | |
|
75.16 KB,
image/png
|
Details | |
|
82.22 KB,
image/png
|
Details | |
|
95.64 KB,
image/png
|
Details | |
|
104.52 KB,
image/png
|
Details |
User Agent: Mozilla/5.0 (X11; Linux x86_64; rv:134.0) Gecko/20100101 Firefox/134.0
Steps to reproduce:
Connect an external display to my phone and start DeX mode.
Open Firefox and navigate to any website.
Hardware used:
Samsung Galaxy S24 Ultra
Lapdock from Dopesplay
Firefox version:
134.0b3
Actual results:
There is a huge white space between the address bar and the viewport.
Additionally, it only sometimes openes new websites in desktop mode.
And the website are scaled a bit to large either mobile or desktop mode.
My lapdock has a 14.1'' screen and a smaller scale would be better.
Expected results:
No white space between the address bar and the viewport.
Better detection for external displays and ther size+resolution.
If not possible, an seperate scaling option for external displays and a seperate setting for automatic desktop layout.
Comment 1•10 months ago
|
||
The Bugbug bot thinks this bug should belong to the 'Fenix::Toolbar' component, and is moving the bug to that component. Please correct in case you think the bot is wrong.
| Reporter | ||
Comment 3•10 months ago
|
||
This problem exists in the stable release too, but the white space ist a bit smaller.
Comment 4•10 months ago
|
||
I can confirm this problem, Samsung S24 FE. (Sidenote: if Mozilla devs need a phone, S24 and S24 FE are considerably more affordable than S24+ and S24 Ultra.)
The whitespace not only is annoying, but it also means we cannot reach the bottom-most portion of any page, as it is always rendered off-screen (well, off-window).
Comment 5•10 months ago
|
||
The blank space at the top is not always white, but it shouldn't be there anyway. And in the screenshot the page was scrolled all the way to the bottom, and yet the bottom-most portion was not accessible. In fact, I cannot press the button on this very form to submit this comment, as it is off-screen.
| Reporter | ||
Comment 6•10 months ago
|
||
(In reply to Denilson Figueiredo de Sá from comment #5)
Created attachment 9442347 [details]
Screenshot_Firefox_Samsung_DeX.pngThe blank space at the top is not always white
Depends on dark mode enabled or not.
| Reporter | ||
Comment 7•10 months ago
|
||
This bug is not everytime.
Sometimes everything looks good.
And it stays good, until you close and reopen Firefox.
But i don't know how to get this on purpose.
Only had it twice.
Updated•9 months ago
|
Comment 8•9 months ago
|
||
I've noticed a similar bug on Firefox Focus, also on Samsung DeX. Whenever I manage to take some screenshots, I'll upload them here.
Comment 9•9 months ago
|
||
Screenshot of the non-buggy behavior. I got this by following these steps:
- Close both apps (Firefox and Firefox Focus).
- Force-stop both apps. (This will ensure they are unloaded, and the next launch will force them to start up from a fresh state.)
- Use Samsung DeX, by connecting the phone to an external monitor.
- Launch both apps from the Samsung DeX UI.
- (Bonus) scroll down to the bottom-most part of the page.
We can see the page zoom level is better adapted to the large screen size. It's still not perfect, I think Firefox assumes the aspect-ratio and/or resolution and/or dimensions won't change, and then stuff gets too big or too small when the window is resized.
Additionally, it seems we can't scroll to the very bottom of the page. The "Submit" button on this bugzilla page is partly off-screen.
If I close each app (Firefox and Firefox Focus), and then go one step further and Force-Stop them to make sure they are unloaded;
Comment 10•9 months ago
|
||
Buggy behavior. I followed these steps:
- Close down both apps (Firefox and Firefox Focus).
- Launched both apps on the phone itself. (i.e. using the phone touchscreen and the phone UI)
- Connected the phone to an external monitor.
- (Re-)Launched both apps on the Samsung DeX UI.
This definitely causes the weird margins at the top of the window. The page zoom also looks off, things are too big. Looks like the apps are still doing calculations based on the phone-sized screen, instead of the big screen of the Samsung DeX.
| Reporter | ||
Comment 11•7 months ago
|
||
Is this an old problem?
1875669 - Wrong resolution on external display (DeX)
Comment 12•7 months ago
|
||
(In reply to Jan Saathoff [:XXLPoseidon] from comment #11)
Is this an old problem?
1875669 - Wrong resolution on external display (DeX)
I don't think so. I never had this white bar before (although I haven't used Dex on an external monitor in a while). I can check again on my tab S8, maybe this is a regression. Or maybe it only affects phones.
What you could try to do is consult whatismyviewport.com to see if the reported size and dpi is identical on both the screen phone and the dex screen (and maybe compare with chrome for example). What I think is happening in my bug is that Firefox doesn't update it's viewport settings depending on which screen it is running on.
Comment 13•6 months ago
|
||
Comment 14•6 months ago
|
||
Comment 15•6 months ago
|
||
Comment 16•6 months ago
|
||
Comment 17•6 months ago
|
||
Comment 18•6 months ago
|
||
Comment 19•6 months ago
|
||
Comment 20•6 months ago
|
||
Comment 21•6 months ago
|
||
Comment 22•6 months ago
|
||
Comment 23•6 months ago
|
||
I've added screenshots of the browsers showing https://whatismyviewport.com/
I followed the same steps on both Firefox and Firefox Focus:
- Force Stop to make sure it will be freshly started.
- Open the browser on DeX, maximize the window, open that webpage.
- Take a screenshot.
- Disconnect DeX, open the same browser on the phone, without closing the browser.
- Take a screenshot.
- Force Stop to make sure it will be freshly started.
- Open the browser on the phone, open that webpage.
- Take a screenshot.
- Connect DeX, open the same browser on DeX, without closing the browser.
- Take a screenshot,
For comparison, I also took two screenshots of Google Chrome.
Additionally, I had to use a chromium/blink-based browser to attach those screenshots to this bug, because the bottom portion of this bugzilla page cannot be reached in Firefox on DeX.
Comment 24•6 months ago
|
||
I have been able to reproduce the behaviour (the gap shown in the first screenshot you sent). I am also pretty sure both our bugs have the same origin, which is GeckoView does not respond to a change in density of the screen.
Steps to reproduce in a regular android emulator :
- Launch Fenix in landscape, in private mode (optionally go to whatismyviewport.com, private mode is to better see the purple gap)
- Open the adb shell, and change the display density with a command like
wm density 160-> will set the DPI to 1 on Chrome and freshly launched Fenix.wm density resetcan be used to go back to the default value.
We can observe that the reported DPI stays the same, and a gap has formed between the bottom of the toolbar and the start of the browser content. What's more, if we measure the number of pixels between the top and bottom of the app View (where the browser content should start) and the top of the app View and the top of the Browser content (where the browser content actually starts), we get a ratio between them of exactly the initially reported display density (2.61 in the case of the attached screenshot). Thus I suppose that the Browser Content is placed on the screen at coordinates calculated with the old density value in mind.
I have been able to to a bit of debugging, and it appears that GeckoView reacts only to a change in resolution of the underlying Surface it draws on (see https://github.com/mozilla/gecko-dev/blob/656899de75c7fdc27c650b701748d508cf6a1bee/mobile/android/geckoview/src/main/java/org/mozilla/geckoview/GeckoView.java#L128), but the surface itself doesn't have any info on the display density. Indeed, Fenix behaves just fine if we instead change the display resolution through adb (wm size 1920x1080 for example). But the Surface itself doesn't hold any information about pixel density, and I haven't seen anywhere in the Java codebase where the app could signal the underlying Gecko runtime about such a change.
I have no clear idea on how to address the issue currently, I might do more research if time allows, but currently I can only share my findings in hope it will be useful to someone else...
Comment 25•6 months ago
|
||
We can measure in this image the distance in pixels between the top of the App View (just under the Android status bar) and either the bottom of the toolbar, and the top of the browser content, and observe that the ratio between them corresponds to the ratio between the old and densities. The density is probably used as a scaling factor when positioning the browser content, and is not updated when the screen's density changes.
| Reporter | ||
Comment 26•3 months ago
|
||
Any updates on this?
Has a developer looked at this yet?
Planned Version to fix this?
| Reporter | ||
Comment 27•3 months ago
|
||
Same Bug, but on another device type:
1940051 - Empty space above the page/below address bar while using this app on Samsung Dex + XReal One glass.
Comment 28•2 months ago
|
||
Same bug here, on Samsung Galaxy S25 connected to a 1080p monitor.
The firt launch of Firefox went ok, but after i disconnected and riconnected the device from the monitor Firefox started showing the huge white bar below the address bar...
Description
•