iDroid Explorer iDroid Explorer - 3 months ago 23
Javascript Question

Full screen option not available when loading YouTube video in WebView

I have work so many time with the webview with in android app. But this time I got strange issue with loading youtube video in to WebView.

See, this is the screen shot of youtube video loaded in chrome browser, which have full screen option in it.

enter image description here

Now, below is the screen shot of my app in which I have loaded same video in webview. But it is not having that full screen option.

enter image description here

You can see the changes in both the images. Both the screen shots are taken from same device. But still it looks different.

My code for webView loading is HERE IN THIS LINK.

I hope there might be way to do it. Need some help in it.
Thanks.

UPDATE

I have also seen that the same issue is reported HERE. But don't know whether is there solution for that available or not.

Sincerely,
Shreyash

M D M D
Answer

iFrame is an option but you can try this

Android's WebView and WebChromeClient class extensions that enable fully working HTML5 video support

VideoEnabledWebView

I have not try this yet but hope will help to you.

Comments