diff options
author | Victoria Lease <violets@google.com> | 2012-03-16 14:56:25 -0700 |
---|---|---|
committer | Android (Google) Code Review <android-gerrit@google.com> | 2012-03-16 14:56:25 -0700 |
commit | 9737a6067423b583d55256e9a6acdee390dfb09d (patch) | |
tree | 3192f88f923ffc1bcbfefe25e2d59eff0d178f35 /Source | |
parent | 24b596eeb936f9a4fdf72b897d66edbddb584a85 (diff) | |
parent | e2e14129682e13146903edf80c205b3c90fd6c90 (diff) | |
download | external_webkit-9737a6067423b583d55256e9a6acdee390dfb09d.zip external_webkit-9737a6067423b583d55256e9a6acdee390dfb09d.tar.gz external_webkit-9737a6067423b583d55256e9a6acdee390dfb09d.tar.bz2 |
Merge "only report actual changes to matchCount"
Diffstat (limited to 'Source')
-rw-r--r-- | Source/WebKit/android/jni/WebViewCore.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/Source/WebKit/android/jni/WebViewCore.cpp b/Source/WebKit/android/jni/WebViewCore.cpp index 4fbf6ed..9aaec25 100644 --- a/Source/WebKit/android/jni/WebViewCore.cpp +++ b/Source/WebKit/android/jni/WebViewCore.cpp @@ -4232,13 +4232,14 @@ int WebViewCore::findTextOnPage(const WTF::String &text) frame->document()->markers()->removeMarkers(DocumentMarker::TextMatch); m_matchCount += frame->editor()->countMatchesForText(text, findOptions, 0, true); - updateMatchCount(); frame->editor()->setMarkedTextMatchesAreHighlighted(true); frame = frame->tree()->traverseNextWithWrap(false); } while (frame); - m_activeMatchIndex = m_matchCount - 1; // prime first findNext - findNextOnPage(true); + if (!m_matchCount) // send at least one update, even if no hits + updateMatchCount(); + else + findNextOnPage(true); return m_matchCount; } |