Chromium Code Reviews| Index: ui/message_center/notification_list.cc |
| diff --git a/ui/message_center/notification_list.cc b/ui/message_center/notification_list.cc |
| index 611d4e89a432fda8d5ab333b57d7454cea3ced6d..996db5a54b2cc34f1e320e258cda9a9b4e77453c 100644 |
| --- a/ui/message_center/notification_list.cc |
| +++ b/ui/message_center/notification_list.cc |
| @@ -160,10 +160,6 @@ bool NotificationList::SetNotificationButtonIcon( |
| return true; |
| } |
| -bool NotificationList::HasNotification(const std::string& id) { |
| - return GetNotification(id) != notifications_.end(); |
| -} |
| - |
| bool NotificationList::HasNotificationOfType(const std::string& id, |
| const NotificationType type) { |
| Notifications::iterator iter = GetNotification(id); |
| @@ -271,6 +267,14 @@ void NotificationList::SetQuietMode(bool quiet_mode) { |
| } |
| } |
| +Notification* NotificationList::GetNotificationById(const std::string& id) { |
| + Notifications::iterator iter = GetNotification(id); |
| + if (iter != notifications_.end()) |
| + return *iter; |
| + else |
|
dewittj
2014/06/09 19:59:10
nit: no else clause, just return null
juyik
2014/06/09 21:28:08
Done.
|
| + return NULL; |
| +} |
| + |
| NotificationList::Notifications NotificationList::GetVisibleNotifications( |
| const NotificationBlockers& blockers) const { |
| Notifications result; |