Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2858)

Unified Diff: content/renderer/render_frame_impl.cc

Issue 2186113002: Fix find-in-page re-scope across frame boundaries. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | third_party/WebKit/Source/web/WebLocalFrameImpl.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/render_frame_impl.cc
diff --git a/content/renderer/render_frame_impl.cc b/content/renderer/render_frame_impl.cc
index d2030c35e017a83ed17e6526dbb2907d173b90c1..833c38c96b87da89f86445c09663a18f64cd7300 100644
--- a/content/renderer/render_frame_impl.cc
+++ b/content/renderer/render_frame_impl.cc
@@ -5226,15 +5226,13 @@ void RenderFrameImpl::OnFind(int request_id,
}
WebRect selection_rect;
- bool active_now = false;
// If something is selected when we start searching it means we cannot just
// increment the current match ordinal; we need to re-generate it.
WebRange current_selection = frame_->selectionRange();
bool result = frame_->find(request_id, search_text, options,
- false /* wrapWithinFrame */, &selection_rect,
- &active_now);
+ false /* wrapWithinFrame */, &selection_rect);
if (result && !options.findNext) {
// Indicate that at least one match has been found. 1 here means possibly
// more matches could be coming. -1 here means that the exact active match
@@ -5243,7 +5241,8 @@ void RenderFrameImpl::OnFind(int request_id,
gfx::Rect(), false /* final_status_update */ );
}
- if (options.findNext && current_selection.isNull() && active_now) {
+ if (options.findNext && current_selection.isNull() &&
+ !frame_->scopingInProgress()) {
dcheng 2016/07/28 02:11:45 Is this an urgent fix? I think we should explore m
// Force report of the actual count.
frame_->increaseMatchCount(0, request_id);
return;
« no previous file with comments | « no previous file | third_party/WebKit/Source/web/WebLocalFrameImpl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698