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 #include "apps/app_lifetime_monitor.h" | 5 #include "apps/app_lifetime_monitor.h" |
6 | 6 |
7 #include "apps/app_window.h" | 7 #include "apps/app_window.h" |
8 #include "chrome/browser/chrome_notification_types.h" | 8 #include "chrome/browser/chrome_notification_types.h" |
9 #include "chrome/browser/extensions/extension_host.h" | |
10 #include "chrome/browser/profiles/profile.h" | 9 #include "chrome/browser/profiles/profile.h" |
11 #include "content/public/browser/notification_details.h" | 10 #include "content/public/browser/notification_details.h" |
12 #include "content/public/browser/notification_service.h" | 11 #include "content/public/browser/notification_service.h" |
| 12 #include "extensions/browser/extension_host.h" |
13 #include "extensions/common/extension.h" | 13 #include "extensions/common/extension.h" |
14 | 14 |
15 namespace apps { | 15 namespace apps { |
16 | 16 |
17 using extensions::Extension; | 17 using extensions::Extension; |
18 using extensions::ExtensionHost; | 18 using extensions::ExtensionHost; |
19 | 19 |
20 AppLifetimeMonitor::AppLifetimeMonitor(Profile* profile) | 20 AppLifetimeMonitor::AppLifetimeMonitor(Profile* profile) |
21 : profile_(profile) { | 21 : profile_(profile) { |
22 registrar_.Add( | 22 registrar_.Add( |
(...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
120 | 120 |
121 void AppLifetimeMonitor::NotifyAppStop(const std::string& app_id) { | 121 void AppLifetimeMonitor::NotifyAppStop(const std::string& app_id) { |
122 FOR_EACH_OBSERVER(Observer, observers_, OnAppStop(profile_, app_id)); | 122 FOR_EACH_OBSERVER(Observer, observers_, OnAppStop(profile_, app_id)); |
123 } | 123 } |
124 | 124 |
125 void AppLifetimeMonitor::NotifyChromeTerminating() { | 125 void AppLifetimeMonitor::NotifyChromeTerminating() { |
126 FOR_EACH_OBSERVER(Observer, observers_, OnChromeTerminating()); | 126 FOR_EACH_OBSERVER(Observer, observers_, OnChromeTerminating()); |
127 } | 127 } |
128 | 128 |
129 } // namespace apps | 129 } // namespace apps |
OLD | NEW |