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

Unified Diff: chrome/browser/ui/webui/ntp/suggestions_source_discovery.cc

Issue 10647003: Discovery API supports specifying a tile in a URL. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Modified experimental discovery API documentation. Created 8 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/browser/ui/webui/ntp/suggestions_source_discovery.cc
diff --git a/chrome/browser/ui/webui/ntp/suggestions_source_discovery.cc b/chrome/browser/ui/webui/ntp/suggestions_source_discovery.cc
index 2aa595579c5a28a8051c1405af46fd94265e2d8b..4e89fbe069769b4ff174bda8e3d0cb6f2d7edc12 100644
--- a/chrome/browser/ui/webui/ntp/suggestions_source_discovery.cc
+++ b/chrome/browser/ui/webui/ntp/suggestions_source_discovery.cc
@@ -76,6 +76,9 @@ void SuggestionsSourceDiscovery::FetchItems(Profile* profile) {
ASCIIToUTF16((*it)->link_text()),
GURL((*it)->link_url()));
page_value->SetDouble("score", (*it)->score());
+ const std::string& url_image = (*it)->url_image();
+ if (url_image.length() > 0)
Evan Stade 2012/07/26 04:26:02 I don't think there's any need for this check.
beaudoin 2012/07/26 17:08:37 It is needed because url_image is an optional para
+ page_value->SetString("urlImage", url_image);
items_.push_back(page_value);
}
combiner_->OnItemsReady();

Powered by Google App Engine
This is Rietveld 408576698