我必须开发一个 android 应用程序。这里的 webvicw 视频播放良好..但是如果我必须单击全屏模式意味着视频崩溃了...我该如何解决这些错误...
如何在全屏模式下播放视频???或者我如何使用 youtube 播放器播放视频???请给我任何建议???
我使用以下代码:
content.setWebChromeClient(new WebChromeClient());
final Activity activity = this;
content.setWebChromeClient(new WebChromeClient(){
public void onProgressChanged ( WebView view , int progress ){
activity.setProgress(progress * 1000);
}
});
content.setWebViewClient(new WebViewClient(){
public void onReceivedError ( WebView view , int errorCode , String description , String failingUrl ){
Toast.makeText(activity, "Oh no! " + description, Toast.LENGTH_SHORT).show();
}
});
content.setWebChromeClient(new WebChromeClient());
content.setScrollBarStyle(View.SCROLLBARS_INSIDE_OVERLAY);
content.getSettings().setJavaScriptEnabled(true);
content.getSettings().setDomStorageEnabled(true);
content.getSettings().setPluginState(PluginState.ON);
content.loadDataWithBaseURL(null, full_content, "text/html", "utf-8", null);