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

Unified Diff: chrome/browser/ui/tab_contents/core_tab_helper.cc

Issue 939713003: Enabled the "search web for image" context menu item when "Yandex" (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 10 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/browser/ui/tab_contents/core_tab_helper.cc
diff --git a/chrome/browser/ui/tab_contents/core_tab_helper.cc b/chrome/browser/ui/tab_contents/core_tab_helper.cc
index 0e52c8dc14589e30a60777fd86bccb0cfafae8d3..efafe7bee3d84b4b806ea6fb00d4bee409e4217a 100644
--- a/chrome/browser/ui/tab_contents/core_tab_helper.cc
+++ b/chrome/browser/ui/tab_contents/core_tab_helper.cc
@@ -244,6 +244,7 @@ bool CoreTabHelper::OnMessageReceived(
// request based on the received thumbnail and opens the request in a new tab.
void CoreTabHelper::OnRequestThumbnailForContextNodeACK(
const std::string& thumbnail_data,
+ const std::string& thumbnail_format,
const gfx::Size& original_size) {
if (thumbnail_data.empty())
return;
@@ -263,6 +264,7 @@ void CoreTabHelper::OnRequestThumbnailForContextNodeACK(
TemplateURLRef::SearchTermsArgs search_args =
TemplateURLRef::SearchTermsArgs(base::string16());
search_args.image_thumbnail_content = thumbnail_data;
+ search_args.image_thumbnail_format = thumbnail_format;
// TODO(jnd): Add a method in WebContentsViewDelegate to get the image URL
// from the ContextMenuParams which creates current context menu.
search_args.image_url = GURL();

Powered by Google App Engine
This is Rietveld 408576698