moved reset calls into new reset method of main activity

This commit is contained in:
Philipp Schaefer
2014-08-19 02:29:02 +02:00
parent 585c16ef72
commit 0fc57f8cfc
2 changed files with 11 additions and 6 deletions

View File

@ -225,13 +225,14 @@ public class IITC_WebViewClient extends WebViewClient {
@Override
public boolean shouldOverrideUrlLoading(final WebView view, final String url) {
if (url.contains("conflogin") || url.contains("ServiceLogin") || url.contains("appengine.google.com")) {
mIitcInjected = false;
Log.d("Google login");
return false;
}
else if (url.contains("ingress.com")) {
if (!mIitcInjected) return false;
mIitc.loadUrl(url);
Log.d("intel link requested, reset app and load " + url);
mIitc.reset();
mIitc.setLoadingState(true);
return false;
} else {
Log.d("no ingress intel link, start external app to load url: " + url);
final Intent intent = new Intent(Intent.ACTION_VIEW, Uri.parse(url));