can't full screen video on webview

476 views Asked by At

Hi I'm loading a video website on a webview. But I can't full screen my videos

this is my manifest

`<application android:name="com.simarkets.app4.MyApp3"
    android:allowBackup="true"
    android:hardwareAccelerated="true"
    android:icon="@drawable/ic_launcher"
    android:label="@string/app_name"
    android:theme="@style/AppTheme">

    <activity
        android:name="com.simarkets.app4.MainActivity"
        android:icon="@drawable/ic_launcher"
        android:hardwareAccelerated="true"
        android:configChanges="orientation|screenSize"
        android:label="@string/app_name" >`

This is my activity

public class MainActivity extends ActionBarActivity {

private InterstitialAd interstitial;

@SuppressLint({ "SetJavaScriptEnabled", "NewApi" }) @Override
protected void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setContentView(R.layout.activity_main);      

    String url = "http://m.youtube.com";
    WebView view = (WebView) this.findViewById(R.id.webView1);
    view.getSettings().setJavaScriptEnabled(true);
    view.getSettings().setPluginState(PluginState.ON);
    view.getSettings().setBuiltInZoomControls(true);
    view.getSettings().setSupportZoom(true);
    view.getSettings().setDisplayZoomControls(false);


    view.setWebViewClient(new WebViewClient()   
        {
            public boolean shouldOverrideUrlLoading(WebView view, String url) 
                {
                    System.out.println("hello");
                    return false;
                }
            });
    view.loadUrl(url); 
}

any idea? plz

0

There are 0 answers