summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorCary Clark <cary@android.com>2010-08-25 16:22:15 -0400
committerCary Clark <cary@android.com>2010-08-25 16:22:15 -0400
commitd64f4a983df4fd11795e04896d8c48852f6b1777 (patch)
tree8c266cff0d0eb87c50e439922582d74397f39224
parentb8814dce287552c1bdf13fa999296ebc7387776d (diff)
downloadframeworks_base-d64f4a983df4fd11795e04896d8c48852f6b1777.zip
frameworks_base-d64f4a983df4fd11795e04896d8c48852f6b1777.tar.gz
frameworks_base-d64f4a983df4fd11795e04896d8c48852f6b1777.tar.bz2
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
-rw-r--r--core/java/android/webkit/WebView.java6
1 files changed, 4 insertions, 2 deletions
diff --git a/core/java/android/webkit/WebView.java b/core/java/android/webkit/WebView.java
index 3e0187d..f8e60ce 100644
--- a/core/java/android/webkit/WebView.java
+++ b/core/java/android/webkit/WebView.java
@@ -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();
}