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

Unified Diff: chrome/renderer/searchbox/searchbox.cc

Issue 20501002: Adds paste function to searchbox api and handles paste event on fakebox (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Adds optional text param to paste. Also adds drop behavior to fakebox. Created 7 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
Index: chrome/renderer/searchbox/searchbox.cc
diff --git a/chrome/renderer/searchbox/searchbox.cc b/chrome/renderer/searchbox/searchbox.cc
index e184eab50d84b2f9c296e58552242ed131a5a929..02395c518bd01e1f42c0f8e6e55ae4b790f26dbe 100644
--- a/chrome/renderer/searchbox/searchbox.cc
+++ b/chrome/renderer/searchbox/searchbox.cc
@@ -231,6 +231,11 @@ void SearchBox::NavigateToURL(const GURL& url,
url, transition, disposition, is_search_type));
}
+void SearchBox::Paste(const string16& text) {
+ render_view()->Send(new ChromeViewHostMsg_SearchBoxPaste(
+ render_view()->GetRoutingID(), render_view()->GetPageId(), text));
+}
+
void SearchBox::SetVoiceSearchSupported(bool supported) {
render_view()->Send(new ChromeViewHostMsg_SetVoiceSearchSupported(
render_view()->GetRoutingID(), render_view()->GetPageId(), supported));

Powered by Google App Engine
This is Rietveld 408576698