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

Unified Diff: chrome/browser/ui/views/ash/balloon_view_ash.cc

Issue 11651002: Updated multiple item notification view to match latest mockups (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years 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 | « no previous file | ui/message_center/message_center.gyp » ('j') | ui/message_center/message_view_multiple.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/views/ash/balloon_view_ash.cc
diff --git a/chrome/browser/ui/views/ash/balloon_view_ash.cc b/chrome/browser/ui/views/ash/balloon_view_ash.cc
index b443e66ce2d8d6365386c2781767a9e4d9e61614..0bc5aa0ad34355f97a4aea5dad8056c1e0adec2c 100644
--- a/chrome/browser/ui/views/ash/balloon_view_ash.cc
+++ b/chrome/browser/ui/views/ash/balloon_view_ash.cc
@@ -24,15 +24,13 @@
#include "ipc/ipc_message_macros.h"
#include "ui/gfx/image/image_skia.h"
#include "ui/message_center/message_center.h"
+#include "ui/message_center/message_center_constants.h"
#include "webkit/glue/image_resource_fetcher.h"
namespace {
typedef base::Callback<void(const std::string&, const gfx::ImageSkia&)> Setter;
-const int kPrimaryIconImageSize = 64;
-const int kSecondaryIconImageSize = 15;
-
// Static.
message_center::MessageCenter* GetMessageCenter() {
return ash::Shell::GetInstance()->GetWebNotificationTray()->message_center();
@@ -194,27 +192,12 @@ void BalloonViewAsh::DownloadImages(const Notification& notification) {
center->SetNotificationPrimaryIcon(notification_id_, notification.icon());
} else if (!notification.icon_url().is_empty()) {
GetImageDownload(notification.icon_url()).AddCallback(
- kPrimaryIconImageSize,
+ message_center::kNotificationIconWidth,
base::Bind(
&message_center::MessageCenter::SetNotificationPrimaryIcon,
base::Unretained(center)));
}
- // Set up a download for the notification's secondary icon if appropriate.
- const base::DictionaryValue* optional_fields = notification.optional_fields();
- if (optional_fields &&
- optional_fields->HasKey(ui::notifications::kSecondIconUrlKey)) {
- string16 url;
- optional_fields->GetString(ui::notifications::kSecondIconUrlKey, &url);
- if (!url.empty()) {
- GetImageDownload(GURL(url)).AddCallback(
- kSecondaryIconImageSize,
- base::Bind(
- &message_center::MessageCenter::SetNotificationSecondaryIcon,
- base::Unretained(center)));
- }
- }
-
// Start the downloads.
for (ImageDownloads::const_iterator i = downloads_.begin();
i != downloads_.end();
« no previous file with comments | « no previous file | ui/message_center/message_center.gyp » ('j') | ui/message_center/message_view_multiple.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698