Chromium Code Reviews| Index: chrome/browser/background/background_contents_service.cc |
| diff --git a/chrome/browser/background/background_contents_service.cc b/chrome/browser/background/background_contents_service.cc |
| index d437f321d9daaf234c81ccb065ff1a4224778d5e..5b77ce2632322c786f32a38ef7d80c57b3195714 100644 |
| --- a/chrome/browser/background/background_contents_service.cc |
| +++ b/chrome/browser/background/background_contents_service.cc |
| @@ -58,6 +58,8 @@ |
| #if defined(ENABLE_NOTIFICATIONS) |
| #include "ui/message_center/message_center.h" |
| +#include "ui/message_center/notification_types.h" |
| +#include "ui/message_center/notifier_settings.h" |
| #endif |
| using content::SiteInstance; |
| @@ -68,6 +70,7 @@ using extensions::UnloadedExtensionInfo; |
| namespace { |
| +const char kNotifierId[] = "app.background.crashed"; |
|
Peter Beverloo
2015/10/09 12:55:23
micro nit: alphabetise (you do it elsewhere).
johnme
2015/10/09 14:20:41
Done.
|
| const char kNotificationPrefix[] = "app.background.crashed."; |
| bool g_disable_close_balloon_for_testing = false; |
| @@ -170,12 +173,17 @@ void NotificationImageReady( |
| // Origin URL must be different from the crashed extension to avoid the |
| // conflict. NotificationSystemObserver will cancel all notifications from |
| // the same origin when NOTIFICATION_EXTENSION_UNLOADED_DEPRECATED. |
| - Notification notification(GURL("chrome://extension-crash"), |
| + Notification notification(message_center::NOTIFICATION_TYPE_SIMPLE, |
| base::string16(), |
| message, |
| notification_icon, |
| + message_center::NotifierId( |
| + message_center::NotifierId::SYSTEM_COMPONENT, |
| + kNotifierId), |
| base::string16(), |
| + GURL("chrome://extension-crash"), |
| delegate->id(), |
| + message_center::RichNotificationData(), |
| delegate.get()); |
| g_browser_process->notification_ui_manager()->Add(notification, profile); |