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

Unified Diff: chrome/browser/notifications/notification.h

Issue 14631005: Enable users of NotificationUIManager to specify binary images. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Remove fake image from synced notification, stop checking icon_url in unit test. Created 7 years, 7 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: chrome/browser/notifications/notification.h
diff --git a/chrome/browser/notifications/notification.h b/chrome/browser/notifications/notification.h
index bbbe73f10bf5e8c7b486f124c1cfd4ab5eac7aa8..93dafd846feb8e72b8d6d80ffca182263c23874b 100644
--- a/chrome/browser/notifications/notification.h
+++ b/chrome/browser/notifications/notification.h
@@ -15,6 +15,7 @@
#include "googleurl/src/gurl.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/WebTextDirection.h"
#include "ui/gfx/image/image.h"
+#include "ui/message_center/notification.h"
#include "ui/message_center/notification_types.h"
// Representation of a notification to be shown to the user.
@@ -65,6 +66,17 @@ class Notification {
const string16& replace_id,
NotificationDelegate* delegate);
+ Notification(
+ message_center::NotificationType type,
+ const GURL& origin_url,
+ const string16& title,
+ const string16& body,
+ WebKit::WebTextDirection dir,
+ const string16& display_source,
+ const string16& replace_id,
+ const message_center::RichNotificationData& rich_notification_data,
+ NotificationDelegate* delegate);
+
Notification(const Notification& notification);
~Notification();
Notification& operator=(const Notification& notification);
@@ -122,6 +134,11 @@ class Notification {
return delegate()->GetRenderViewHost();
}
+ bool has_rich_notification() const { return has_rich_notification_; }
+ const message_center::RichNotificationData& rich_notification_data() const {
+ return rich_notification_data_;
+ }
+
NotificationDelegate* delegate() const { return delegate_.get(); }
private:
@@ -159,6 +176,9 @@ class Notification {
scoped_ptr<DictionaryValue> optional_fields_;
+ bool has_rich_notification_;
+ message_center::RichNotificationData rich_notification_data_;
+
// A proxy object that allows access back to the JavaScript object that
// represents the notification, for firing events.
scoped_refptr<NotificationDelegate> delegate_;

Powered by Google App Engine
This is Rietveld 408576698