randolph249 / iscroll-js

Automatically exported from code.google.com/p/iscroll-js
MIT License
0 stars 0 forks source link

iScroll example pages overlap with status bar in full-screen #26

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
(iScroll 3.6 on iPad running iOS 3.2 and iPhone 4 running iOS 4.0.1)

Steps to reproduce:
1. Go to one of the examples included with the iScroll code.
2. Add to home screen. Load from home screen (should take up full screen).
3. The header overlaps with the status bar.

If I add margin-top: 20px; to the body, the status bar and header no longer 
overlap in full-screen mode, but then it looks wrong when viewing the page 
normally in Mobile Safari.

Original issue reported on code.google.com by jvcreati...@gmail.com on 5 Sep 2010 at 5:23

GoogleCodeExporter commented 8 years ago
Addendum: this only applies when the black-translucent status bar style is used 
before adding to home screen. If the black or default style is used, the 
overlap doesn't occur. I supposed this is expected behavior for the 
black-translucent style, but should iScroll accommodate this somehow?

Original comment by jvcreati...@gmail.com on 5 Sep 2010 at 9:31

GoogleCodeExporter commented 8 years ago
That's to be expected. Opaque status bar styles (normal, black) sit above the 
page. The black translucent style sits over the page, with 20px of content 
behind it. Nothing to do with iScroll.

Original comment by bamber...@gmail.com on 6 Sep 2010 at 2:00

GoogleCodeExporter commented 8 years ago

Original comment by mat...@gmail.com on 6 Sep 2010 at 6:33

GoogleCodeExporter commented 8 years ago
I thought that might be the case. Is there a way to detect the full-screen mode 
and add the 20px margin automatically?

Original comment by jvcreati...@gmail.com on 6 Sep 2010 at 9:46

GoogleCodeExporter commented 8 years ago
Yes. Its a property of navigator I think. Try Googling 'safari iPhone is web 
app fullscreen'

I think you can choose the style of status bar with a Meta tag too :)

Original comment by bamber...@gmail.com on 6 Sep 2010 at 4:34

GoogleCodeExporter commented 8 years ago
Thanks. This article was helpful:
http://www.bennadel.com/blog/1950-Detecting-iPhone-s-App-Mode-Full-Screen-Mode-F
or-Web-Applications.htm

Original comment by jvcreati...@gmail.com on 6 Sep 2010 at 10:37