Index: chrome/browser/notifications/persistent_notification_delegate.cc |
diff --git a/chrome/browser/notifications/persistent_notification_delegate.cc b/chrome/browser/notifications/persistent_notification_delegate.cc |
index 9ac9837ca4ff262d59334bfde5d8ce0ccc20657f..4dd80dca44d0d6c8e96e03282447c2fd8b460030 100644 |
--- a/chrome/browser/notifications/persistent_notification_delegate.cc |
+++ b/chrome/browser/notifications/persistent_notification_delegate.cc |
@@ -6,7 +6,7 @@ |
#include "base/bind.h" |
#include "base/guid.h" |
-#include "chrome/browser/notifications/platform_notification_service_impl.h" |
+#include "content/public/browser/notification_event_dispatcher.h" |
#include "content/public/common/persistent_notification_status.h" |
namespace { |
@@ -19,13 +19,11 @@ void OnEventDispatchComplete(content::PersistentNotificationStatus status) {} |
PersistentNotificationDelegate::PersistentNotificationDelegate( |
content::BrowserContext* browser_context, |
- int64 service_worker_registration_id, |
- const GURL& origin, |
- const content::PlatformNotificationData& notification_data) |
+ int64_t persistent_notification_id, |
+ const GURL& origin) |
: browser_context_(browser_context), |
- service_worker_registration_id_(service_worker_registration_id), |
+ persistent_notification_id_(persistent_notification_id), |
origin_(origin), |
- notification_data_(notification_data), |
id_(base::GenerateGUID()) {} |
PersistentNotificationDelegate::~PersistentNotificationDelegate() {} |
@@ -35,13 +33,12 @@ void PersistentNotificationDelegate::Display() {} |
void PersistentNotificationDelegate::Close(bool by_user) {} |
void PersistentNotificationDelegate::Click() { |
- PlatformNotificationServiceImpl::GetInstance()->OnPersistentNotificationClick( |
- browser_context_, |
- service_worker_registration_id_, |
- id_, |
- origin_, |
- notification_data_, |
- base::Bind(&OnEventDispatchComplete)); |
+ content::NotificationEventDispatcher::GetInstance() |
+ ->DispatchNotificationClickEvent( |
+ browser_context_, |
+ persistent_notification_id_, |
+ origin_, |
+ base::Bind(&OnEventDispatchComplete)); |
} |
std::string PersistentNotificationDelegate::id() const { |