sindresorhus / screenfull

Simple wrapper for cross-browser usage of the JavaScript Fullscreen API
https://sindresorhus.com/screenfull
MIT License
7.06k stars 698 forks source link

screenfull fails in native browser on Android 4.4.2 #61

Closed mwinkelm closed 9 years ago

mwinkelm commented 9 years ago

Hi,

although I don't think this is an issue with screenfull.js, I want to bring this fact to your attention.

In my application I rely on the screenfull.raw.fullscreenchange event to initialize/load some content in the element (a DIV container) that was brought to fullscreen if supported.

I tested the app with the Samsung Galaxy Tab 4 (SM-T530) that has Android 4.4.2 installed. Is use the native browser and wonder why no content is loaded.

I figured out, that in this browser screenfull.enabled is equal to true, although it doesn't support the W3C Fullscreen API.

As screenfull.js detects the new WebKit syntax as available in this browser, it assumes the browser has fullscreen capabilities. Refering to this page http://www.jwplayer.com/html5/fullscreen/ the browser may only support these functions for html5 video?

So in this state I'm not able to detect fullscreen support for other DOM elements than video in a reliable manner.

Can anyone confirm this behavior on another android device? You can use the screenfull.js demo site http://sindresorhus.com/screenfull.js/ to test your native (android) browser.

Thanks, Markus

sindresorhus commented 9 years ago

Duplicate of #56