Issue metadata
Sign in to add a comment
|
on successful element.requestFullscreen(), top Android bar hides, but browser window does not take the space left by the top bar
Reported by
ppec...@gmail.com,
Dec 22 2016
|
||||||||||||||||||||||
Issue descriptionSteps to reproduce the problem: Any use of the full screen API call on Portrait mode What is the expected behavior? Android top bar hides and browser takes all screen space What went wrong? Top Android bar hides but browser does not take its space, leaving an empty dead space at the top. If you change orientation to Landscape and back to Portrait it now takes the space, and the "Drag from top ... to exit full screen" appears. Did this work before? Yes 55 Does this work in other browsers? Yes Chrome version: 56 Channel: beta OS Version: 6.0.1 Flash Version:
,
Dec 22 2016
,
Dec 22 2016
Yes, seems highly likely. Thanks.
,
Dec 22 2016
I can't seem to repro on any test cases I build. ppeccin@, could you provide a test case or url that shows the problem?
,
Dec 22 2016
My MSX emulator. Its a big project, but will show the problem: http://webmsx.org/alpha Right after you click "NICE!" it will go full screen. Notice the dead space at the top. If you change to Landscape, it will fix the dead space, and then if you change back to Portrait it will remain fixed and only them the "Drag from...to exit full screen" message appears. In my Samsung Galaxy S6 with Chrome Beta.
,
Dec 22 2016
Interesting, it seems to work correctly for me in both Beta (56.0.2924.23) and Dev (57.0.2950.3) on both Nexus 5X and Nexus 6. What's the exact chrome version string you're using?
,
Dec 22 2016
Its the latest beta that shows for my device: 56.0.2942.23 Maybe some device or Android version specific issue? Galaxy S6 Android 6.0.1 here. From my recent experience with Chrome testing and behavior, there are many things that work well on Nexus devices and poorly on other devices. Do you guys run tests at least on recent devices from other vendors?
,
Dec 22 2016
bokan@, did the blue screen expanded all the way to the top for you right after clicking "NICE!"? Did the "Drag from top...to exit full screen" message appear immediately? For me, both happen only after I change to Landscape then back to Portrait. Works OK in version 55.
,
Dec 22 2016
Yes, both happen for me without resorting to rotation. We should even have some Galaxy S6 bots but tests don't always catch everything. I wouldn't expect this to be platform dependent either. Anyway, I'll try to hunt down a Samsung device and get back to you.
,
Dec 22 2016
For me this seems like some timing or sequencing issue related to how Android is hiding the bar. Maybe different version or distros of Android behave a little differently. On version 55, I can see that first the same as on 56 happens, than right immediately after the bar completely hides and the window finishes "growing" up to the top. Now on 56 it stops at the first step.
,
Dec 22 2016
Ok, I did manage to reproduce on a Galaxy S7. The "dead-zone" is from the System tool bar, rather than the Android URL bar as I initially assumed so this is unrelated to the change made in issue 428132 . +foolip@ who's been doing some fullscreen work and may have some ideas.
,
Dec 22 2016
The problem is worse when you use "Add to Home Screen" function, then run your WebApp in STANDALONE mode. When you launch it, there is an empty space at the bottom, with the same height as the Android System bar, even without entering full screen. It seems unrelated to the full screen mode, and maybe has something to do with the URL bar hiding. I am using "position: absolute; height: 100%;" Something is wrong with the height of the browser available space. You can test this by using that same webapp of mine: http://webmsx.org/alpha Add it to the Home Screen, then launch from the installed icon. Look at the screen without touching it and you will see the empty space at the bottom. On the first touch it will go full screen. It was working beautifully in 55, with the standalone window taking all available space (besides the System Bar, of course, that only goes away when entering full screen)
,
Dec 22 2016
Should I create a new issue for the standalone mode???
,
Dec 22 2016
No, if it started at the same time it's likely related to the same issue. I'll take another look.
,
Dec 22 2016
Ok. There are 2 different issues, one affecting full screen and another one affecting standalone mode. Maybe that are related, maybe not. Thank you
,
Dec 23 2016
I've reproduced the issue with "Add to Homescreen" even on my N6. Turning off the inert top controls flag fixes the issue so it's definitely related to issue 428132 . I'll try to land a fix ASAP
,
Dec 26 2016
Another related issue: 1) Load a website. My website is also good to test this: http://webmsx.org 2) Notice the Top Address Bar is showing, and the website takes all available height, leaving no scroll possible 3) Go to full screen mode (in my site, it will happen after you click "NICE!") 4) Go back to normal mode (just touch Android BACK) 5) The Address Bar is now HIDDEN, and that breaks the layout leaving an empty white space at the bottom. Still no scroll possible Many websites (including mine) try to adapt the layout to use 100% of the available HEIGHT, with height: 100% or height: 100vh. Chrome should remember whether the Address Bar was showing before you entered full screen, and restore to the same state when you leave full screen. Or maybe always return with the Address Bar hidden but update the CSS calculations to let the website take the full height again. Version 56 is not doing this right, and that leaves an empty unusable space at the bottom.
,
Jan 2 2017
This may be the regression of some of my recent changes, but it's not at all certain. Adding Needs-Bisect label to get some idea.
,
Jan 3 2017
I've actually narrowed it down to my change to layout height so no bisect needed. I'm working on a fix right now.
,
Jan 3 2017
Sorry, I mistakenly thought this was assigned to me when I added that label.
,
Jan 4 2017
Turns out there actually is a small URL bar that's used for security purposes in "WebApp" mode. If you navigate your app to a different domain, we show a small ~22px URL bar for security purposes. We're currently shrinking layout by that amount even though it doesn't show up when the page is scrolled. I've got a fix where we'll just use full screen height if the controls are in a "locked" state like in the WebApp case. I'll have to give it a try on a Galaxy phone but hopefully that'll fix the issue there too.
,
Jan 4 2017
Please, I'm very interested in this fix. Tell me if you need any testing, and how to get the fixed version.
,
Jan 5 2017
Thanks, here's an APK with my fix you can install and try: https://drive.google.com/open?id=0B8erhfwi4twRSGpWNGNRUnFSUVk This should fix the "Add to Homescreen" issue though I haven't tried the web browser fullscreen issue you were having on the Galaxy S6. I've ordered a Galaxy phone to try myself but you can give it a try in the mean time.
,
Jan 5 2017
The Add to Home Screen is fixed. But the full screen mode still has the same problem: there is a small unused space at the top, approx. the same space normally taken by the Android System Bar. If you change orientation it gets fixed, and only after you return to portrait then Chrome knows its in full screen mode and shows the "to exit full screen..." message. Paulo
,
Jan 5 2017
Ok, thanks. I've split the "Add to homescreen" issue off into issue 678649 and will land that fix shortly. I'll leave this open to fix the fullscreen mode issue, will likely need to wait until Monday when my Galaxy phone arrives.
,
Jan 11 2017
I've started looking at the browser fullscreen issue. It seems that turning off the change to URL bar resizing behavior doesn't help so this is a regression introduced elsewhere. I'll try a bisect to narrow it down.
,
Jan 12 2017
Bisect points to: commit b026e994a4822fadddccc99cc10cf431e2e97066 author tedchoc <tedchoc@chromium.org> Wed Nov 16 01:36:44 2016 Use only renderer driven offsets for fullscreen state. Ted, any idea why this patch might be causing this? The space at the top is from the Android system bar. My guess would be we have a race between going fullscreen and the system bar hiding that we reliably win on Nexus devices but not on Galaxy. I've attached a screen cap, the blue area should be all the way at the top of the image but there's a black rect that we don't give to the page. Inspecting in dev tools shows that the page isn't aware that space is available to it.
,
Jan 12 2017
I think that patch exposed some timing issues with BrowserControlsOffsetManager The fact that on page load the renderer initializes the controls as hidden and the browser assumes they're shown. The fact that it works is entirely a wonky code path, see comment here: https://codereview.chromium.org/2484293003#msg11 So yeah, the code has races...lots of them.
,
Jan 12 2017
In this case though, it's the system bar, rather than the URL bar. In any case, are we willing to live with this for a release or shall I keep the RBS label?
,
Jan 12 2017
I suspect it is caused by the same thing. We only trigger hiding the system bar when the renderer tells us the controls are fully hidden: https://cs.chromium.org/chromium/src/chrome/android/java/src/org/chromium/chrome/browser/fullscreen/ChromeFullscreenManager.java?l=475 I.e. the control hidden ratio reaches 1.0. I suspect the renderer is never sending it (likely because it thinks they are fully hidden to begin with while the browser does not).
,
Jan 12 2017
If this is breaking all fullscreen api usage, it seems like it should be RBS.
,
Jan 12 2017
Did we know what caused this, and why it was working perfectly in v55?
,
Jan 12 2017
It's a bug exposed by the patch above. I'm digging into this today to find the exact cause and hopefully figure out a way to fix it.
,
Jan 13 2017
Just FYI, you're using RB without a milestone - which means it's invisible to us :X Adding M-56 to track. ppeccin@, this means that at least as of this writing we'll fix this issue before M56 goes to stable (per our discussion on the other bug).
,
Jan 13 2017
Nice. Please, also pay attention to Comment 17. Its another problem of wrong page height when you go in/out of FullScreen mode. But that one is related to the URL Bar, not the Android System Bar. On v55 all of this was working beautifully. No problems...
,
Jan 13 2017
I suspect it's related, our fullscreen enter/exit notifications on Samsung devices seem to not be firing correctly because the Navigation bar (buttons) are hardware buttons rather than part of layout. The URL bar should always be shown on exit from fullscreen.
,
Jan 13 2017
ppeccin@, I have a potential fix up for review - it solves both the status bar and issue in #17. You can try it out and confirm: https://drive.google.com/file/d/0B8erhfwi4twRSGpWNGNRUnFSUVk/view?usp=sharing (debug build so extra slow)
,
Jan 14 2017
Tested it, but no... The problem persists. Its like the previous test apk posted. Only the Standalone mode problem is solved, the ones related to FullScreen mode are still there.
,
Jan 15 2017
Sorry, uploaded the wrong build. The one up now should be correct: https://drive.google.com/file/d/0B8erhfwi4twRSGpWNGNRUnFSUVk/view?usp=sharing
,
Jan 15 2017
Yes! Both Full Screen and Standalone problems gone! But still one issue related to URL Bar hiding that did not happen in v55: for a page that takes 100% height in portrait, if you go to landscape, do some scroll to make the bar hide, then go back to portrait, the bar keeps hidden, but page layout is as if the bar was still showing, which in my case produces a white empty space at the bottom. That did not happen in v55: the bar was also hidden, but page layout was right, taking all available height. You can see this in my page: http://webmsx.org I wish everything was just as in v54... Thanks! On Jan 15, 2017 18:02, "bo… via monorail" <monorail+v2.3285626211@ chromium.org> wrote:
,
Jan 15 2017
That's by design because of the fix to issue 428132 . There's more details here: https://developers.google.com/web/updates/2016/12/url-bar-resizing If you do want to fill the viewport, you can either make your container position: fixed or size it on the resize event to window.innerWidth/window.innerHeight (assuming you disabled pinch-zoom).
,
Jan 15 2017
Wow... Then I think it would be better if the URL Bar shows again automatically if you change orientation and the new height is 100%. There is no good in leaving the bar hidden if the layout + bar would fit exactly on the screen with no scroll possible. It would be better than leaving empty space at the bottom... Just my opinion!
,
Jan 15 2017
#42 - the behavior should be the same as iOS Safari, does your page work the same there?
,
Jan 15 2017
It's something that I've considered, Safari does this but it's generally more aggressive about showing the URL bar. Though others would would prefer we leave the URL bar hidden as it's less intrusive and on many pages, we'd just fill the bottom with the background color so it would look fine. It's a trade-off so I think we'll have to see whether this ends up looking bad on a significant proportion of content.
,
Jan 15 2017
Re#43: This is actually one difference between Chrome and Safari, Safari shows the URL bar in more situations than Chrome.
,
Jan 16 2017
Well, I really prefer the behavior from v55. 100% means all available space. Safari behavior is anoying... Now its strange. If you make your page 100% height, sometimes it will hit the bottom perfectly, sometimes there will be space. If you make it height: fixed, the bar will hide the top of the page?
,
Jan 18 2017
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/8e1c144ac1b517fb8406a3a3d17e9b3ed3aeb911 commit 8e1c144ac1b517fb8406a3a3d17e9b3ed3aeb911 Author: bokan <bokan@chromium.org> Date: Wed Jan 18 14:48:07 2017 Fix for fullscreen layout timing on Galaxy devices. Move the requestLayout call to happen after SustemUiVisibility changes. BUG= 676634 Review-Url: https://codereview.chromium.org/2635563002 Cr-Commit-Position: refs/heads/master@{#444352} [modify] https://crrev.com/8e1c144ac1b517fb8406a3a3d17e9b3ed3aeb911/chrome/android/java/src/org/chromium/chrome/browser/fullscreen/FullscreenHtmlApiHandler.java
,
Jan 18 2017
The patch is landed in ToT. I'll wait until I can confirm it in Canary and request merge.
,
Jan 19 2017
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/0c8ae63da637ec94525728b9bb256ba475056e49 commit 0c8ae63da637ec94525728b9bb256ba475056e49 Author: bokan <bokan@chromium.org> Date: Thu Jan 19 03:28:49 2017 Revert of Fix for fullscreen layout timing on Galaxy devices. (patchset #2 id:20001 of https://codereview.chromium.org/2635563002/ ) Reason for revert: Fullscreen tests breaking on Clank builders. BUG=682353 Original issue's description: > Fix for fullscreen layout timing on Galaxy devices. > > Remove the requestLayout call in enterFullscreen > > BUG= 676634 > > Review-Url: https://codereview.chromium.org/2635563002 > Cr-Commit-Position: refs/heads/master@{#444352} > Committed: https://chromium.googlesource.com/chromium/src/+/8e1c144ac1b517fb8406a3a3d17e9b3ed3aeb911 TBR=tedchoc@chromium.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG= 676634 Review-Url: https://codereview.chromium.org/2645793002 Cr-Commit-Position: refs/heads/master@{#444623} [modify] https://crrev.com/0c8ae63da637ec94525728b9bb256ba475056e49/chrome/android/java/src/org/chromium/chrome/browser/fullscreen/FullscreenHtmlApiHandler.java
,
Jan 19 2017
Patch was breaking downstream Clank bots. Will try to reland a fixed patch.
,
Jan 20 2017
We only have until Monday afternoon to land a fix if you want to merge to M56, so please prioritize (though it looks like you're actively working on this, thanks!)
,
Jan 20 2017
I have a new candidate patch up for review already. Hope to have it landed by tomorrow
,
Jan 20 2017
Can I have a build for testing?
,
Jan 20 2017
Updated https://drive.google.com/open?id=0B8erhfwi4twRSGpWNGNRUnFSUVk with the patch currently up for review.
,
Jan 20 2017
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/6432d4b76477d8587270c0bc75689ae0f13aa989 commit 6432d4b76477d8587270c0bc75689ae0f13aa989 Author: bokan <bokan@chromium.org> Date: Fri Jan 20 16:28:37 2017 Fix for fullscreen layout timing on Galaxy devices. Remove the requestLayout call in enterFullscreen BUG= 676634 Review-Url: https://codereview.chromium.org/2635563002 Cr-Original-Commit-Position: refs/heads/master@{#444352} Committed: https://chromium.googlesource.com/chromium/src/+/8e1c144ac1b517fb8406a3a3d17e9b3ed3aeb911 Review-Url: https://codereview.chromium.org/2635563002 Cr-Commit-Position: refs/heads/master@{#445070} [modify] https://crrev.com/6432d4b76477d8587270c0bc75689ae0f13aa989/chrome/android/java/src/org/chromium/chrome/browser/fullscreen/FullscreenHtmlApiHandler.java
,
Jan 20 2017
Patch is landed in ToT, I'm going to let the Clank downstream bots cycle this before merging. amineer@, because we're close to M56 should I just confirm in ToT rather than waiting for Canary roll?
,
Jan 20 2017
We can wait for a canary on Monday, let's just make sure it's merged same day. Thanks!
,
Jan 20 2017
Will do, thanks.
,
Jan 23 2017
Fix is confirmed in latest canary (58.0.2989.0). Requesting merge to 56.
,
Jan 23 2017
This bug requires manual review: Reverts referenced in bugdroid comments after merge request. Please contact the milestone owner if you have questions. Owners: amineer@(clank), cmasso@(bling), gkihumba@(cros), bustamante@(desktop) For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
,
Jan 23 2017
FYI: The patch in #55 is in ToT. It references a previous land/revert.
,
Jan 23 2017
Merge approved for M56 branch 2924.
,
Jan 23 2017
,
Jan 23 2017
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/448886672a32876b9921ce5c1fef3334b5bd9f43 commit 448886672a32876b9921ce5c1fef3334b5bd9f43 Author: David Bokan <bokan@chromium.org> Date: Mon Jan 23 17:38:54 2017 Fix for fullscreen layout timing on Galaxy devices. Remove the requestLayout call in enterFullscreen BUG= 676634 Review-Url: https://codereview.chromium.org/2635563002 Cr-Original-Commit-Position: refs/heads/master@{#444352} Committed: https://chromium.googlesource.com/chromium/src/+/8e1c144ac1b517fb8406a3a3d17e9b3ed3aeb911 Review-Url: https://codereview.chromium.org/2635563002 Cr-Commit-Position: refs/heads/master@{#445070} (cherry picked from commit 6432d4b76477d8587270c0bc75689ae0f13aa989) Review-Url: https://codereview.chromium.org/2654523002 . Cr-Commit-Position: refs/branch-heads/2924@{#840} Cr-Branched-From: 3a87aecc31cd1ffe751dd72c04e5a96a1fc8108a-refs/heads/master@{#433059} [modify] https://crrev.com/448886672a32876b9921ce5c1fef3334b5bd9f43/chrome/android/java/src/org/chromium/chrome/browser/fullscreen/FullscreenHtmlApiHandler.java
,
Jan 23 2017
Ok, this should be fixed when the next Beta gets pushed.
,
Feb 19 2017
Hello, this issue is back in Chrome 57 for android, on my Galaxy S6. I have updated my Chromes in my Galaxy S6, both production and Beta. Now the production (56) has the fix and is working correctly, but the Beta (57) has the exact same problem again.
,
Feb 21 2017
Ah, thanks for bringing it up. The fix landed just after 57 branched so we need to merge it back there too. I've confirmed M58 is working as expected.
,
Feb 21 2017
This bug requires manual review: Reverts referenced in bugdroid comments after merge request. Please contact the milestone owner if you have questions. Owners: amineer@(clank), cmasso@(bling), ketakid@(cros), govind@(desktop) For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
,
Feb 21 2017
Approved for M57 branch 2987
,
Feb 21 2017
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/99aebb1a1882c523732711da31bb6d10205ea7d3 commit 99aebb1a1882c523732711da31bb6d10205ea7d3 Author: bokan <bokan@chromium.org> Date: Tue Feb 21 18:19:13 2017 Fix for fullscreen layout timing on Galaxy devices. Remove the requestLayout call in enterFullscreen BUG= 676634 Review-Url: https://codereview.chromium.org/2635563002 Cr-Original-Commit-Position: refs/heads/master@{#444352} Committed: https://chromium.googlesource.com/chromium/src/+/8e1c144ac1b517fb8406a3a3d17e9b3ed3aeb911 Review-Url: https://codereview.chromium.org/2635563002 Cr-Commit-Position: refs/heads/master@{#445070} (cherry picked from commit 6432d4b76477d8587270c0bc75689ae0f13aa989) Review-Url: https://codereview.chromium.org/2705283002 . Cr-Commit-Position: refs/branch-heads/2987@{#611} Cr-Branched-From: ad51088c0e8776e8dcd963dbe752c4035ba6dab6-refs/heads/master@{#444943} [modify] https://crrev.com/99aebb1a1882c523732711da31bb6d10205ea7d3/chrome/android/java/src/org/chromium/chrome/browser/fullscreen/FullscreenHtmlApiHandler.java
,
Feb 21 2017
Fix is now merged to M57. I'll confirm on the next Beta push.
,
Feb 21 2017
Issue 694558 has been merged into this issue. |
|||||||||||||||||||||||
►
Sign in to add a comment |
|||||||||||||||||||||||
Comment 1 by phistuck@chromium.org
, Dec 22 2016