Fix captive portal can't show certificate problem

Captive portal overrides two shouldOverrideUrlLoading methods,
but show certificate logic only be implemented in deprecated one.

Bug: 133714666
Test: -build, flash, boot
      -atest FramworksNetTests
      -manual test

Change-Id: I2656bb709cb0bf259279ca75ad8411cd8c92fb43
Merged-In: I64b05adcb46baf3fca116dbdc5177bc31c71e06d
(cherry picked from commit 9161b5e845)
This commit is contained in:
Mark Chien
2019-05-29 19:46:04 -07:00
parent daf8086aa0
commit cd31d19710

View File

@@ -485,7 +485,10 @@ public class CaptivePortalLoginActivity extends Activity {
if (request.isForMainFrame()) {
mMainFrameUrl = request.getUrl().toString();
}
return false;
// Be careful that two shouldOverrideUrlLoading methods are overridden, but
// shouldOverrideUrlLoading(WebView view, String url) was deprecated in API level 24.
// TODO: delete deprecated one ??
return shouldOverrideUrlLoading(view, mMainFrameUrl);
}
// A web page consisting of a large broken lock icon to indicate SSL failure.