Fullscreen-API-Polyfill icon indicating copy to clipboard operation
Fullscreen-API-Polyfill copied to clipboard

Support for iOS webkit

Open commonpike opened this issue 9 years ago • 4 comments
trafficstars

I see no support for webkitEnterFullscreen and friends; in particular webkitDisplayingFullscreen requires a different approach to polyfill, because its a property of an element, not of the document.

commonpike avatar Mar 30 '16 18:03 commonpike

Yes, I don't think it should be supported in this polyfill ; I intend to stick to the specification.

webkitEnterFullscreen is used only on <video> elements (correct me if I'm wrong) ; webkit is also implementing the specification using a prefix (which this polyfill might hopefully ease).

There is still the case of iOS which allows webkitEnterFullscreen but not the specification. I think the better is to manually check for webkitEnterFullscreen on <video> elements when necessary.

neovov avatar Mar 31 '16 06:03 neovov

Yes, I was actually looking for a polyfill that handled the latter case - webkitEnterFullscreen and not the specs. Older ipads still have it. So I thought I'd drop a note here to let people know its not here.

I've tried to shim it myself now, mimicing the events (which it doesnt have at all) based on resize events. I keep track of fullscreenElement myself.

commonpike avatar Mar 31 '16 09:03 commonpike

It seems every iOS have webkitEnterFullscreen and not the standard specification.

For the events, it seems (not sure if the link will work properly, check the "Full-Screen Event and Properties" section) you will have to use the proprietary webkitbeginfullscreen and webkitendfullscreen.

Now I'm not sure if the polyfill should play nice and support this API too.

neovov avatar Mar 31 '16 09:03 neovov

PS .. thanks for the links. fyi webkitbeginfullscreen and webkitendfullscreen trigger on the video element, and don't seem to propagate to the body. but its better than resize :-)

commonpike avatar Mar 31 '16 12:03 commonpike