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

Unified Diff: content/child/notifications/pending_notifications_tracker.cc

Issue 1634933006: Use NotificationResources instead of a bare SkBitmap. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix unit tests. Created 4 years, 11 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: content/child/notifications/pending_notifications_tracker.cc
diff --git a/content/child/notifications/pending_notifications_tracker.cc b/content/child/notifications/pending_notifications_tracker.cc
index 2ee031d4b6741b5aba12c9a61c13b7457f8c0e57..588af7552e3d26983581af1316e1a652cd66894d 100644
--- a/content/child/notifications/pending_notifications_tracker.cc
+++ b/content/child/notifications/pending_notifications_tracker.cc
@@ -8,7 +8,7 @@
#include "base/location.h"
#include "base/thread_task_runner_handle.h"
#include "content/child/notifications/notification_image_loader.h"
-#include "content/child/notifications/notification_manager.h"
+#include "content/public/common/notification_resources.h"
#include "third_party/WebKit/public/platform/modules/notifications/WebNotificationData.h"
#include "third_party/skia/include/core/SkBitmap.h"
@@ -75,7 +75,9 @@ void PendingNotificationsTracker::DidFetchPageNotification(
pending_notifications_.Lookup(notification_id);
DCHECK(pending_notification);
- pending_notification->callback.Run(icon);
+ NotificationResources notification_resources;
+ notification_resources.notification_icon = icon;
+ pending_notification->callback.Run(notification_resources);
delegate_to_pending_id_map_.erase(delegate);
pending_notifications_.Remove(notification_id);
@@ -87,7 +89,9 @@ void PendingNotificationsTracker::DidFetchPersistentNotification(
pending_notifications_.Lookup(notification_id);
DCHECK(pending_notification);
- pending_notification->callback.Run(icon);
+ NotificationResources notification_resources;
+ notification_resources.notification_icon = icon;
+ pending_notification->callback.Run(notification_resources);
pending_notifications_.Remove(notification_id);
}
« no previous file with comments | « content/child/notifications/pending_notifications_tracker.h ('k') | content/common/platform_notification_messages.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698