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 #include "chrome/browser/notifications/message_center_notification_manager.h" | 5 #include "chrome/browser/notifications/message_center_notification_manager.h" |
6 | 6 |
7 #include <memory> | 7 #include <memory> |
8 #include <utility> | 8 #include <utility> |
9 | 9 |
10 #include "base/logging.h" | 10 #include "base/logging.h" |
(...skipping 16 matching lines...) Expand all Loading... |
27 #include "ui/message_center/message_center_style.h" | 27 #include "ui/message_center/message_center_style.h" |
28 #include "ui/message_center/message_center_tray.h" | 28 #include "ui/message_center/message_center_tray.h" |
29 #include "ui/message_center/message_center_types.h" | 29 #include "ui/message_center/message_center_types.h" |
30 #include "ui/message_center/notifier_settings.h" | 30 #include "ui/message_center/notifier_settings.h" |
31 | 31 |
32 #if defined(OS_CHROMEOS) | 32 #if defined(OS_CHROMEOS) |
33 #include "chrome/browser/notifications/login_state_notification_blocker_chromeos
.h" | 33 #include "chrome/browser/notifications/login_state_notification_blocker_chromeos
.h" |
34 #endif | 34 #endif |
35 | 35 |
36 #if defined(USE_ASH) | 36 #if defined(USE_ASH) |
37 #include "ash/common/system/web_notification/web_notification_tray.h" | |
38 #include "ash/shell.h" | 37 #include "ash/shell.h" |
| 38 #include "ash/system/web_notification/web_notification_tray.h" |
39 #endif | 39 #endif |
40 | 40 |
41 using message_center::NotifierId; | 41 using message_center::NotifierId; |
42 | 42 |
43 MessageCenterNotificationManager::MessageCenterNotificationManager( | 43 MessageCenterNotificationManager::MessageCenterNotificationManager( |
44 message_center::MessageCenter* message_center, | 44 message_center::MessageCenter* message_center, |
45 std::unique_ptr<message_center::NotifierSettingsProvider> settings_provider) | 45 std::unique_ptr<message_center::NotifierSettingsProvider> settings_provider) |
46 : message_center_(message_center), | 46 : message_center_(message_center), |
47 settings_provider_(std::move(settings_provider)), | 47 settings_provider_(std::move(settings_provider)), |
48 system_observer_(this), | 48 system_observer_(this), |
(...skipping 287 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
336 } | 336 } |
337 | 337 |
338 ProfileNotification* MessageCenterNotificationManager::FindProfileNotification( | 338 ProfileNotification* MessageCenterNotificationManager::FindProfileNotification( |
339 const std::string& id) const { | 339 const std::string& id) const { |
340 auto iter = profile_notifications_.find(id); | 340 auto iter = profile_notifications_.find(id); |
341 if (iter == profile_notifications_.end()) | 341 if (iter == profile_notifications_.end()) |
342 return nullptr; | 342 return nullptr; |
343 | 343 |
344 return (*iter).second.get(); | 344 return (*iter).second.get(); |
345 } | 345 } |
OLD | NEW |