Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    text
    copied!<p>I also suffer from this problem, I solved this problem by customizing Dialog, here is my custom dialog code, hope so this is use full for you. </p> <pre><code> TwitterDialog fb=new TwitterDialog(this); fb.abc(); //fb.dismiss(); class TwitterDialog extends Dialog { Context context; String url="https://accounts.google.com/ServiceLogin?service=mail&amp;passive=true&amp;rm=false&amp;continue=https://mail.google.com/mail/&amp;ss=1&amp;scc=1&amp;ltmpl=default&amp;ltmplcache=2"; public TwitterDialog(Context context) { super(context); this.context=context; } void abc(){ LinearLayout mContent = new LinearLayout(context); mContent.setOrientation(LinearLayout.VERTICAL); final float scale = context.getResources().getDisplayMetrics().density; float[] dimensions =new float[]{400.0f,500.0f}; addContentView(mContent, new FrameLayout.LayoutParams( (int) (dimensions[0] * scale + 0.5f), (int) (dimensions[1] * scale + 0.5f))); FrameLayout.LayoutParams FILL = new FrameLayout.LayoutParams(ViewGroup.LayoutParams.FILL_PARENT, ViewGroup.LayoutParams.FILL_PARENT); WebView mWebView = new WebView(context); mWebView.setVerticalScrollBarEnabled(false); mWebView.setHorizontalScrollBarEnabled(false); mWebView.setWebViewClient(new WebClicent()); mWebView.getSettings().setJavaScriptEnabled(true); mWebView.loadUrl(url); mWebView.setLayoutParams(FILL); mContent.addView(mWebView); TwitterDialog.this.show(); } class WebClicent extends WebViewClient{ @Override public void onLoadResource(WebView view, String url) { System.out.println("onLoadResource "+url); super.onLoadResource(view, url); } @Override public void onPageFinished(WebView view, String url) { System.out.println("onPageFinished "+url); //TwitterDialog.this.dismiss(); super.onPageFinished(view, url); } @Override public void onPageStarted(WebView view, String url, Bitmap favicon) { System.out.println("onPageStarted "+url); super.onPageStarted(view, url, favicon); } } }//TWitterDialog </code></pre>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload