Skip to content

Instantly share code, notes, and snippets.

@TjWallas
Created April 22, 2013 06:59
Show Gist options
  • Save TjWallas/5432924 to your computer and use it in GitHub Desktop.
Save TjWallas/5432924 to your computer and use it in GitHub Desktop.
Embedding Vimeo Videos using WebView on Android
//Auto playing vimeo videos in Android webview
mWebView.getSettings().setJavaScriptEnabled(true);
mWebView.getSettings().setAppCacheEnabled(true);
mWebView.getSettings().setDomStorageEnabled(true);
// how plugin is enabled change in API 8
if (Build.VERSION.SDK_INT < 8) {
mWebView.getSettings().setPluginsEnabled(true);
} else {
mWebView.getSettings().setPluginState(PluginState.ON);
}
mWebView.loadUrl("http://player.vimeo.com/video/24577973?player_id=player&autoplay=1&title=0&byline=0&portrait=0&api=1&maxheight=480&maxwidth=800");
@sergiobarbieri
Copy link

Hi, any tips for enabling full screen???

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment