Untitled

mail@pastecode.io avatar
unknown
plain_text
a year ago
858 B
1
Indexable
Never
import android.webkit.WebViewClient;
import android.view.ViewGroup.LayoutParams;
import android.webkit.WebView;
import android.view.ViewGroup;
import android.app.Activity;
import android.widget.RelativeLayout;
import android.widget.FrameLayout;
 
FrameLayout fl;
Activity act;
WebView web;
WebViewClient wbc;
 
 
void settings(){
  fullScreen();
}
 
public void onStart() {
  super.onStart();
 
  act = this.getActivity();
  wbc = new WebViewClient();
  web = new WebView(act);
  //web.setLayoutParams(new RelativeLayout.LayoutParams( RelativeLayout.LayoutParams.WRAP_CONTENT,RelativeLayout.LayoutParams.WRAP_CONTENT));
  web.setWebViewClient(wbc);
  web.getSettings().setJavaScriptEnabled(true);
  web.loadUrl("http:www.netflix.com/");
  fl = (FrameLayout)act.getWindow().getDecorView().getRootView();
  fl.addView(web);
}
 
void setup(){
background(0);
}