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

Unified Diff: chrome/browser/notifications/message_center_display_service.cc

Issue 2906883003: Deprecate per notification type delegates. (Closed)
Patch Set: review Created 3 years, 6 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/BUILD.gn ('k') | chrome/browser/notifications/notification_object_proxy.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/notifications/message_center_display_service.cc
diff --git a/chrome/browser/notifications/message_center_display_service.cc b/chrome/browser/notifications/message_center_display_service.cc
index e04fca35462b7f732e4640d8127925161ddd158e..e7445d73310896bf6cbe655d3ad822330a9f73d6 100644
--- a/chrome/browser/notifications/message_center_display_service.cc
+++ b/chrome/browser/notifications/message_center_display_service.cc
@@ -8,9 +8,11 @@
#include "chrome/browser/notifications/message_center_display_service.h"
#include "chrome/browser/notifications/notification.h"
+#include "chrome/browser/notifications/notification_handler.h"
#include "chrome/browser/notifications/notification_ui_manager.h"
#include "chrome/browser/profiles/profile.h"
#include "content/public/browser/browser_thread.h"
+#include "content/public/browser/notification_event_dispatcher.h"
MessageCenterDisplayService::MessageCenterDisplayService(
Profile* profile,
@@ -28,6 +30,9 @@ void MessageCenterDisplayService::Display(
// TODO(miguelg): MCDS should stop relying on the |notification|'s delegate
// for Close/Click operations once the Notification object becomes a mojom
// type.
+
+ NotificationHandler* handler = GetNotificationHandler(notification_type);
+ handler->OnShow(profile_, notification_id);
ui_manager_->Add(notification, profile_);
}
« no previous file with comments | « chrome/browser/BUILD.gn ('k') | chrome/browser/notifications/notification_object_proxy.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698