public void init() { SSLWLWebView localSSLWLWebView = new SSLWLWebView(this); if (Build.VERSION.SDK_INT < 11); for (Object localObject = new CordovaWebViewClient(this, localSSLWLWebView); ; localObject = new IceCreamCordovaWebViewClient(this, localSSLWLWebView)) { super.init(localSSLWLWebView, (CordovaWebViewClient)localObject, new CordovaChromeClient(this, localSSLWLWebView)); return; } }
public void init() { WLWebView localWLWebView = new WLWebView(this); if (Build.VERSION.SDK_INT < 11); for (Object localObject = new CordovaWebViewClient(this, localWLWebView); ; localObject = new IceCreamCordovaWebViewClient(this, localWLWebView)) { super.init(localWLWebView, (CordovaWebViewClient)localObject, new CordovaChromeClient(this, localWLWebView)); return; } }
/** Called when the activity is first created. */ @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.main); //CB-7238: This has to be added now, because it got removed from somewhere else Config.init(this); cordovaWebView = (CordovaWebView) findViewById(R.id.cordovaWebView); cordovaWebView.init(this, new CordovaWebViewClient(this, cordovaWebView), new CordovaChromeClient(this, cordovaWebView), Config.getPluginEntries(), Config.getWhitelist(), Config.getExternalWhitelist(), Config.getPreferences()); cordovaWebView.loadUrl("file:///android_asset/www/index.html"); }
/** Called when the activity is first created. */ @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); // AWV Factory should be initialized before setting the layout if (!sFactoryInit) { factory = AmazonWebKitFactories.getDefaultFactory(); if (factory.isRenderProcess(this)) { return; // Do nothing if this is on render process } factory.initialize(this); sFactoryInit = true; } else { factory = AmazonWebKitFactories.getDefaultFactory(); } setContentView(R.layout.main); //CB-7238: This has to be added now, because it got removed from somewhere else Config.init(this); cordovaWebView = (CordovaWebView) findViewById(R.id.cordovaWebView); factory.initializeWebView(cordovaWebView, 0xFFFFFF, false, null); cordovaWebView.init(this, new CordovaWebViewClient(this, cordovaWebView), new CordovaChromeClient(this, cordovaWebView), Config.getPluginEntries(), Config.getWhitelist(), Config.getExternalWhitelist(), Config.getPreferences()); cordovaWebView.loadUrl("file:///android_asset/www/index.html"); }
public void testCustom() { assertTrue(CordovaWebView.class.isInstance(testView)); assertTrue(CordovaWebViewClient.class.isInstance(testActivity.testViewClient)); assertTrue(CordovaChromeClient.class.isInstance(testActivity.testChromeClient)); }
private CordovaChromeClient encapsulatedCordovaChromeClientForView(CordovaWebView view) { try { if (reflectionGet(view, "chromeClient") != null) { return new WrappingCordovaChromeClient(null, view); } } catch (NoSuchFieldException nsfe) {} catch (IllegalAccessException iae) {} return new ExtendedCordovaChromeClient(view); }
public void customTest() { assertTrue(CordovaWebView.class.isInstance(testView)); assertTrue(CordovaWebViewClient.class.isInstance(testActivity.testViewClient)); assertTrue(CordovaChromeClient.class.isInstance(testActivity.testChromeClient)); }
@Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); super.init(new CordovaWebView(this), new TestViewClient(this), new CordovaChromeClient(this)); super.loadUrl("file:///android_asset/www/whitelist/index.html"); }
@Override protected CordovaChromeClient makeChromeClient(CordovaWebView webView) { XWebChromeClient chrom = new XWebChromeClient(this, webView); webView.setWebChromeClient(chrom); return chrom; }
public WrappingCordovaChromeClient(CordovaInterface ci, CordovaWebView view) throws NoSuchFieldException, IllegalAccessException { super(ci, view); selendroidCCC = new ExtendedCordovaChromeClient(view); selendroidCCC.callSuper = false; WCC = (CordovaChromeClient) reflectionGet(view, "chromeClient"); }