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

Unified Diff: chrome/browser/find_bar_controller.cc

Issue 660137: Allow users to close the find session and activate the current link via ctrl-... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 10 years, 9 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 | « chrome/browser/find_bar_controller.h ('k') | chrome/browser/find_bar_host_browsertest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/find_bar_controller.cc
===================================================================
--- chrome/browser/find_bar_controller.cc (revision 41087)
+++ chrome/browser/find_bar_controller.cc (working copy)
@@ -34,7 +34,7 @@
find_bar_->SetFocusAndSelection();
}
-void FindBarController::EndFindSession() {
+void FindBarController::EndFindSession(SelectionAction action) {
find_bar_->Hide(true);
// |tab_contents_| can be NULL for a number of reasons, for example when the
@@ -43,8 +43,7 @@
// When we hide the window, we need to notify the renderer that we are done
// for now, so that we can abort the scoping effort and clear all the
// tickmarks and highlighting.
- tab_contents_->StopFinding(false); // false = don't clear selection on
- // page.
+ tab_contents_->StopFinding(action);
find_bar_->ClearResults(tab_contents_->find_result());
// When we get dismissed we restore the focus to where it belongs.
@@ -139,7 +138,7 @@
if (find_bar_->IsFindBarVisible()) {
if (PageTransition::StripQualifier(transition_type) !=
PageTransition::RELOAD) {
- EndFindSession();
+ EndFindSession(kKeepSelection);
} else {
// On Reload we want to make sure FindNext is converted to a full Find
// to make sure highlights for inactive matches are repainted.
« no previous file with comments | « chrome/browser/find_bar_controller.h ('k') | chrome/browser/find_bar_host_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698