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

Unified Diff: chrome/browser/renderer_host/render_view_host.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/renderer_host/render_view_host.h ('k') | chrome/browser/tab_contents/tab_contents.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/renderer_host/render_view_host.cc
===================================================================
--- chrome/browser/renderer_host/render_view_host.cc (revision 41087)
+++ chrome/browser/renderer_host/render_view_host.cc (working copy)
@@ -391,8 +391,24 @@
// The result of the search is sent as a notification message by the renderer.
}
-void RenderViewHost::StopFinding(bool clear_selection) {
- Send(new ViewMsg_StopFinding(routing_id(), clear_selection));
+void RenderViewHost::StopFinding(
+ FindBarController::SelectionAction selection_action) {
+ ViewMsg_StopFinding_Params params;
+
+ switch (selection_action) {
+ case FindBarController::kClearSelection:
+ params.action = ViewMsg_StopFinding_Params::kClearSelection;
+ break;
+ case FindBarController::kKeepSelection:
+ params.action = ViewMsg_StopFinding_Params::kKeepSelection;
+ break;
+ case FindBarController::kActivateSelection:
+ params.action = ViewMsg_StopFinding_Params::kActivateSelection;
+ break;
+ default:
+ NOTREACHED();
+ }
+ Send(new ViewMsg_StopFinding(routing_id(), params));
}
void RenderViewHost::Zoom(PageZoom::Function function) {
« no previous file with comments | « chrome/browser/renderer_host/render_view_host.h ('k') | chrome/browser/tab_contents/tab_contents.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698