| 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" |
| 11 #include "base/observer_list.h" | 11 #include "base/observer_list.h" |
| 12 #include "ui/gfx/native_widget_types.h" | 12 #include "ui/gfx/native_widget_types.h" |
| 13 #include "ui/message_center/message_center_export.h" | 13 #include "ui/message_center/message_center_export.h" |
| 14 #include "ui/message_center/message_center_types.h" | 14 #include "ui/message_center/message_center_types.h" |
| 15 #include "ui/message_center/notification_list.h" | 15 #include "ui/message_center/notification_list.h" |
| 16 #include "ui/message_center/notification_types.h" | 16 #include "ui/message_center/notification_types.h" |
| 17 | 17 |
| 18 class TrayViewControllerTest; | |
| 19 | |
| 20 namespace base { | 18 namespace base { |
| 21 class DictionaryValue; | 19 class DictionaryValue; |
| 22 } | 20 } |
| 23 | 21 |
| 24 // Interface to manage the NotificationList. The client (e.g. Chrome) calls | 22 // Interface to manage the NotificationList. The client (e.g. Chrome) calls |
| 25 // [Add|Remove|Update]Notification to create and update notifications in the | 23 // [Add|Remove|Update]Notification to create and update notifications in the |
| 26 // list. It also sends those changes to its observers when a notification | 24 // list. It also sends those changes to its observers when a notification |
| 27 // is shown, closed, or clicked on. | 25 // is shown, closed, or clicked on. |
| 28 | 26 |
| 29 namespace message_center { | 27 namespace message_center { |
| (...skipping 130 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 160 | 158 |
| 161 // UI classes should call this when there is cause to leave popups visible for | 159 // UI classes should call this when there is cause to leave popups visible for |
| 162 // longer than the default (for example, when the mouse hovers over a popup). | 160 // longer than the default (for example, when the mouse hovers over a popup). |
| 163 virtual void PausePopupTimers() = 0; | 161 virtual void PausePopupTimers() = 0; |
| 164 | 162 |
| 165 // UI classes should call this when the popup timers should restart (for | 163 // UI classes should call this when the popup timers should restart (for |
| 166 // example, after the mouse leaves the popup.) | 164 // example, after the mouse leaves the popup.) |
| 167 virtual void RestartPopupTimers() = 0; | 165 virtual void RestartPopupTimers() = 0; |
| 168 | 166 |
| 169 protected: | 167 protected: |
| 170 friend class ::TrayViewControllerTest; | 168 friend class TrayViewControllerTest; |
| 171 friend class test::MessagePopupCollectionTest; | 169 friend class test::MessagePopupCollectionTest; |
| 172 virtual void DisableTimersForTest() = 0; | 170 virtual void DisableTimersForTest() = 0; |
| 173 | 171 |
| 174 MessageCenter(); | 172 MessageCenter(); |
| 175 virtual ~MessageCenter(); | 173 virtual ~MessageCenter(); |
| 176 | 174 |
| 177 private: | 175 private: |
| 178 DISALLOW_COPY_AND_ASSIGN(MessageCenter); | 176 DISALLOW_COPY_AND_ASSIGN(MessageCenter); |
| 179 }; | 177 }; |
| 180 | 178 |
| 181 } // namespace message_center | 179 } // namespace message_center |
| 182 | 180 |
| 183 #endif // UI_MESSAGE_CENTER_MESSAGE_CENTER_H_ | 181 #endif // UI_MESSAGE_CENTER_MESSAGE_CENTER_H_ |
| OLD | NEW |