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

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

Issue 10821035: wip Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . 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
« no previous file with comments | « chrome/browser/ui/webui/favicon_source.cc ('k') | chrome/browser/ui/webui/ntp/favicon_webui_handler.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/webui/ntp/app_launcher_handler.cc
diff --git a/chrome/browser/ui/webui/ntp/app_launcher_handler.cc b/chrome/browser/ui/webui/ntp/app_launcher_handler.cc
index 2ee60211ef79042b242b470da10a1291a25616fb..5a9938630b20230c69e6e0aaf534cc08070ed75c 100644
--- a/chrome/browser/ui/webui/ntp/app_launcher_handler.cc
+++ b/chrome/browser/ui/webui/ntp/app_launcher_handler.cc
@@ -804,9 +804,10 @@ void AppLauncherHandler::OnFaviconForApp(FaviconService::Handle handle,
WebApplicationInfo::IconInfo icon;
web_app->icons.push_back(icon);
- if (data.is_valid() && gfx::PNGCodec::Decode(data.bitmap_data->front(),
- data.bitmap_data->size(),
- &(web_app->icons[0].data))) {
+ if (data.is_valid() && data.variants.size() > 0 &&
+ gfx::PNGCodec::Decode(data.variants[0].bitmap_data->front(),
+ data.variants[0].bitmap_data->size(),
+ &(web_app->icons[0].data))) {
web_app->icons[0].url = GURL();
web_app->icons[0].width = web_app->icons[0].data.width();
web_app->icons[0].height = web_app->icons[0].data.height();
« no previous file with comments | « chrome/browser/ui/webui/favicon_source.cc ('k') | chrome/browser/ui/webui/ntp/favicon_webui_handler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698