mirror of
https://github.com/Tencent/QMUI_Android.git
synced 2026-10-29 03:26:44 +08:00
it's OK for QMUIWebView to set null to client
This commit is contained in:
@@ -75,7 +75,7 @@ public class QMUIWebView extends WebView implements IWindowInsetLayout {
|
||||
|
||||
@Override
|
||||
public void setWebChromeClient(WebChromeClient client) {
|
||||
if (!(client instanceof QMUIWebChromeClient)) {
|
||||
if (client != null && !(client instanceof QMUIWebChromeClient)) {
|
||||
throw new IllegalArgumentException("must use the instance of QMUIWebChromeClient");
|
||||
}
|
||||
super.setWebChromeClient(client);
|
||||
@@ -83,7 +83,7 @@ public class QMUIWebView extends WebView implements IWindowInsetLayout {
|
||||
|
||||
@Override
|
||||
public void setWebViewClient(WebViewClient client) {
|
||||
if (!(client instanceof QMUIWebViewClient)) {
|
||||
if (client != null && !(client instanceof QMUIWebViewClient)) {
|
||||
throw new IllegalArgumentException("must use the instance of QMUIWebViewClient");
|
||||
}
|
||||
super.setWebViewClient(client);
|
||||
|
||||
Reference in New Issue
Block a user