DO NOT MERGE fix null check
Check to see if the WebChromeClient is null. Checked into master in change 63008 Change-Id: If2ef1889ce3633c0b35c078a46bde84982dd1eb3 http://b/2945171
This commit is contained in:
@@ -3338,7 +3338,8 @@ public class WebView extends AbsoluteLayout
|
||||
setUpSelect();
|
||||
if (mNativeClass != 0 && nativeWordSelection(x, y)) {
|
||||
nativeSetExtendSelection();
|
||||
getWebChromeClient().onSelectionStart(this);
|
||||
WebChromeClient client = getWebChromeClient();
|
||||
if (client != null) client.onSelectionStart(this);
|
||||
return true;
|
||||
}
|
||||
notifySelectDialogDismissed();
|
||||
@@ -4126,7 +4127,8 @@ public class WebView extends AbsoluteLayout
|
||||
*/
|
||||
public void selectionDone() {
|
||||
if (mSelectingText) {
|
||||
getWebChromeClient().onSelectionDone(this);
|
||||
WebChromeClient client = getWebChromeClient();
|
||||
if (client != null) client.onSelectionDone(this);
|
||||
invalidate(); // redraw without selection
|
||||
notifySelectDialogDismissed();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user