| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef UI_MESSAGE_CENTER_NOTIFICATION_BLOCKER_H_ | 5 #ifndef UI_MESSAGE_CENTER_NOTIFICATION_BLOCKER_H_ |
| 6 #define UI_MESSAGE_CENTER_NOTIFICATION_BLOCKER_H_ | 6 #define UI_MESSAGE_CENTER_NOTIFICATION_BLOCKER_H_ |
| 7 | 7 |
| 8 #include "base/observer_list.h" | 8 #include "base/observer_list.h" |
| 9 #include "ui/message_center/message_center_export.h" | 9 #include "ui/message_center/message_center_export.h" |
| 10 #include "ui/message_center/notification.h" | 10 #include "ui/message_center/notification.h" |
| (...skipping 29 matching lines...) Expand all Loading... |
| 40 // When a blocker starts returning false for a notification which is already | 40 // When a blocker starts returning false for a notification which is already |
| 41 // shown as a popup, the notification should be closed as a popup immediately. | 41 // shown as a popup, the notification should be closed as a popup immediately. |
| 42 virtual bool ShouldShowNotificationAsPopup( | 42 virtual bool ShouldShowNotificationAsPopup( |
| 43 const NotifierId& notifier_id) const = 0; | 43 const NotifierId& notifier_id) const = 0; |
| 44 | 44 |
| 45 protected: | 45 protected: |
| 46 MessageCenter* message_center() { return message_center_; } | 46 MessageCenter* message_center() { return message_center_; } |
| 47 void NotifyBlockingStateChanged(); | 47 void NotifyBlockingStateChanged(); |
| 48 | 48 |
| 49 private: | 49 private: |
| 50 ObserverList<Observer> observers_; | 50 base::ObserverList<Observer> observers_; |
| 51 MessageCenter* message_center_; // weak | 51 MessageCenter* message_center_; // weak |
| 52 }; | 52 }; |
| 53 | 53 |
| 54 typedef std::vector<NotificationBlocker*> NotificationBlockers; | 54 typedef std::vector<NotificationBlocker*> NotificationBlockers; |
| 55 | 55 |
| 56 } // namespace message_center | 56 } // namespace message_center |
| 57 | 57 |
| 58 #endif // UI_MESSAGE_CENTER_NOTIFICATION_BLOCKER_H_ | 58 #endif // UI_MESSAGE_CENTER_NOTIFICATION_BLOCKER_H_ |
| OLD | NEW |