diff options
author | Leon Scroggins <scroggo@google.com> | 2010-01-12 14:38:39 -0500 |
---|---|---|
committer | Leon Scroggins <scroggo@google.com> | 2010-01-12 14:38:39 -0500 |
commit | 9fb6b3c382612e4284ca9bd38930ab94053b8888 (patch) | |
tree | ab370e7fb05589a4153f8c8c2bb0a11b1b1d8953 | |
parent | 838afd1be683057ebaf5cf85359bf9a567602b7b (diff) | |
download | external_webkit-9fb6b3c382612e4284ca9bd38930ab94053b8888.zip external_webkit-9fb6b3c382612e4284ca9bd38930ab94053b8888.tar.gz external_webkit-9fb6b3c382612e4284ca9bd38930ab94053b8888.tar.bz2 |
Ensure that the current textfield is actually a textfield before treating it like one.
Fix for http://b/issue?id=2368868
-rw-r--r-- | WebKit/android/nav/CachedRoot.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/WebKit/android/nav/CachedRoot.cpp b/WebKit/android/nav/CachedRoot.cpp index e783eae..d9669bd 100644 --- a/WebKit/android/nav/CachedRoot.cpp +++ b/WebKit/android/nav/CachedRoot.cpp @@ -760,11 +760,11 @@ CachedRoot::ImeAction CachedRoot::currentTextFieldAction() const { const CachedFrame* currentFrame; const CachedNode* current = currentCursor(¤tFrame); - if (!current) { + if (!current || !current->isTextInput()) { // Although the cursor is not on a textfield, a textfield may have // focus. Find the action for that textfield. current = currentFocus(¤tFrame); - if (!current) + if (!current || !current->isTextInput()) // Error case. No cursor and no focus. return FAILURE; } |