OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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_MESSAGE_CENTER_H_ | 5 #ifndef UI_MESSAGE_CENTER_MESSAGE_CENTER_H_ |
6 #define UI_MESSAGE_CENTER_MESSAGE_CENTER_H_ | 6 #define UI_MESSAGE_CENTER_MESSAGE_CENTER_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
(...skipping 107 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
118 // This should be called by UI classes after a visible notification popup | 118 // This should be called by UI classes after a visible notification popup |
119 // closes, indicating that the notification has been shown to the user. | 119 // closes, indicating that the notification has been shown to the user. |
120 // |mark_notification_as_read|, if false, will unset the read bit on a | 120 // |mark_notification_as_read|, if false, will unset the read bit on a |
121 // notification, increasing the unread count of the center. | 121 // notification, increasing the unread count of the center. |
122 virtual void MarkSinglePopupAsShown(const std::string& id, | 122 virtual void MarkSinglePopupAsShown(const std::string& id, |
123 bool mark_notification_as_read) = 0; | 123 bool mark_notification_as_read) = 0; |
124 | 124 |
125 // This should be called by UI classes when a notification is first displayed | 125 // This should be called by UI classes when a notification is first displayed |
126 // to the user, in order to decrement the unread_count for the tray, and to | 126 // to the user, in order to decrement the unread_count for the tray, and to |
127 // notify observers that the notification is visible. | 127 // notify observers that the notification is visible. |
128 virtual void DisplayedNotification(const std::string& id) = 0; | 128 virtual void DisplayedNotification( |
| 129 const std::string& id, |
| 130 const DisplaySource source) = 0; |
129 | 131 |
130 // Setter/getter of notifier settings provider. This will be a weak reference. | 132 // Setter/getter of notifier settings provider. This will be a weak reference. |
131 // This should be set at the initialization process. The getter may return | 133 // This should be set at the initialization process. The getter may return |
132 // NULL for tests. | 134 // NULL for tests. |
133 virtual void SetNotifierSettingsProvider( | 135 virtual void SetNotifierSettingsProvider( |
134 NotifierSettingsProvider* provider) = 0; | 136 NotifierSettingsProvider* provider) = 0; |
135 virtual NotifierSettingsProvider* GetNotifierSettingsProvider() = 0; | 137 virtual NotifierSettingsProvider* GetNotifierSettingsProvider() = 0; |
136 | 138 |
137 // This can be called to change the quiet mode state (without a timeout). | 139 // This can be called to change the quiet mode state (without a timeout). |
138 virtual void SetQuietMode(bool in_quiet_mode) = 0; | 140 virtual void SetQuietMode(bool in_quiet_mode) = 0; |
(...skipping 24 matching lines...) Expand all Loading... |
163 MessageCenter(); | 165 MessageCenter(); |
164 virtual ~MessageCenter(); | 166 virtual ~MessageCenter(); |
165 | 167 |
166 private: | 168 private: |
167 DISALLOW_COPY_AND_ASSIGN(MessageCenter); | 169 DISALLOW_COPY_AND_ASSIGN(MessageCenter); |
168 }; | 170 }; |
169 | 171 |
170 } // namespace message_center | 172 } // namespace message_center |
171 | 173 |
172 #endif // UI_MESSAGE_CENTER_MESSAGE_CENTER_H_ | 174 #endif // UI_MESSAGE_CENTER_MESSAGE_CENTER_H_ |
OLD | NEW |