diff options
author | Paul Jensen <pauljensen@google.com> | 2015-06-09 17:19:38 +0000 |
---|---|---|
committer | Android Git Automerger <android-git-automerger@android.com> | 2015-06-09 17:19:38 +0000 |
commit | 79a4cb7b18f92d9a6adf774818ac7dfe9d8b8cad (patch) | |
tree | 8e2b56547326905a30627c5098666881401f76ab /packages/CaptivePortalLogin | |
parent | d58abdd12f79bebad894ea54973ef57061e7dc15 (diff) | |
parent | 16bef48d2226c72167e3314f2bc48b0f5de61d81 (diff) | |
download | frameworks_base-79a4cb7b18f92d9a6adf774818ac7dfe9d8b8cad.zip frameworks_base-79a4cb7b18f92d9a6adf774818ac7dfe9d8b8cad.tar.gz frameworks_base-79a4cb7b18f92d9a6adf774818ac7dfe9d8b8cad.tar.bz2 |
am 16bef48d: Merge "Add support for tel: links in captive portal app." into mnc-dev
* commit '16bef48d2226c72167e3314f2bc48b0f5de61d81':
Add support for tel: links in captive portal app.
Diffstat (limited to 'packages/CaptivePortalLogin')
-rw-r--r-- | packages/CaptivePortalLogin/src/com/android/captiveportallogin/CaptivePortalLoginActivity.java | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/packages/CaptivePortalLogin/src/com/android/captiveportallogin/CaptivePortalLoginActivity.java b/packages/CaptivePortalLogin/src/com/android/captiveportallogin/CaptivePortalLoginActivity.java index d876264..d00f850 100644 --- a/packages/CaptivePortalLogin/src/com/android/captiveportallogin/CaptivePortalLoginActivity.java +++ b/packages/CaptivePortalLogin/src/com/android/captiveportallogin/CaptivePortalLoginActivity.java @@ -342,6 +342,15 @@ public class CaptivePortalLoginActivity extends Activity { getString(R.string.ssl_error_continue)); view.loadDataWithBaseURL(INTERNAL_ASSETS, html, "text/HTML", "UTF-8", null); } + + @Override + public boolean shouldOverrideUrlLoading (WebView view, String url) { + if (url.startsWith("tel:")) { + startActivity(new Intent(Intent.ACTION_DIAL, Uri.parse(url))); + return true; + } + return false; + } } private class MyWebChromeClient extends WebChromeClient { |