Reputation: 4823
I have to open a website say Facebook page, twitter page and You Tube page in order to share my post there. Now when I click to the item Facebook , it gets redirected to FB to share and same for Twitter and YouTube.
I have to show them in my WebView and all this is done perfectly.
What I want is to show the Progress Dialog after clicking on the Item till it gets redirected to the FB , Twitter or YouTube.
I don know how to show the Progress Bar for redirecting to the Main Website. Can anyone Please help me put Here.
Thanks, David Brown
Upvotes: 0
Views: 122
Reputation: 3025
Sometimes the Twitter Page Contains the DOM data so you need to do the Following:
webViewFollowOn.getSettings().setDomStorageEnabled(true);
I hope it will Help You...:)
Upvotes: 3
Reputation: 763
public class WebviewcontrollerWebClient extends WebViewClient {
public void onPageStarted(WebView view, String url, Bitmap favicon) {
super.onPageStarted(view, url, favicon);
_dialog =ProgressDialog.show(activity, "", "Please wait...");
_dialog.setCanceledOnTouchOutside(true);
_dialog.setCancelable(true);
}
@Override
public void onPageFinished(WebView view, String url) {
if(_dialog!=null)
_dialog.dismiss();
}
Upvotes: 1