| 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 "chrome/browser/apps/ephemeral_app_service.h" | 5 #include "chrome/browser/apps/ephemeral_app_service.h" |
| 6 | 6 |
| 7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
| 8 #include "chrome/browser/apps/ephemeral_app_service_factory.h" | 8 #include "chrome/browser/apps/ephemeral_app_service_factory.h" |
| 9 #include "chrome/browser/chrome_notification_types.h" | 9 #include "chrome/browser/chrome_notification_types.h" |
| 10 #include "chrome/browser/extensions/extension_prefs.h" | |
| 11 #include "chrome/browser/extensions/extension_service.h" | 10 #include "chrome/browser/extensions/extension_service.h" |
| 12 #include "chrome/browser/extensions/extension_system.h" | 11 #include "chrome/browser/extensions/extension_system.h" |
| 13 #include "chrome/browser/extensions/extension_util.h" | 12 #include "chrome/browser/extensions/extension_util.h" |
| 14 #include "chrome/browser/profiles/profile.h" | 13 #include "chrome/browser/profiles/profile.h" |
| 15 #include "chrome/common/chrome_switches.h" | 14 #include "chrome/common/chrome_switches.h" |
| 16 #include "content/public/browser/notification_service.h" | 15 #include "content/public/browser/notification_service.h" |
| 17 #include "content/public/browser/notification_source.h" | 16 #include "content/public/browser/notification_source.h" |
| 18 #include "content/public/browser/notification_types.h" | 17 #include "content/public/browser/notification_types.h" |
| 18 #include "extensions/browser/extension_prefs.h" |
| 19 #include "extensions/common/extension.h" | 19 #include "extensions/common/extension.h" |
| 20 #include "extensions/common/extension_set.h" | 20 #include "extensions/common/extension_set.h" |
| 21 | 21 |
| 22 using extensions::Extension; | 22 using extensions::Extension; |
| 23 using extensions::ExtensionPrefs; | 23 using extensions::ExtensionPrefs; |
| 24 using extensions::ExtensionSet; | 24 using extensions::ExtensionSet; |
| 25 using extensions::ExtensionSystem; | 25 using extensions::ExtensionSystem; |
| 26 using extensions::InstalledExtensionInfo; | 26 using extensions::InstalledExtensionInfo; |
| 27 | 27 |
| 28 namespace { | 28 namespace { |
| (...skipping 190 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 219 // Remove ephemeral apps that have been inactive for a while or if the cache | 219 // Remove ephemeral apps that have been inactive for a while or if the cache |
| 220 // is larger than the desired size. | 220 // is larger than the desired size. |
| 221 if (it->first < inactive_threshold || app_count > kMaxEphemeralAppsCount) { | 221 if (it->first < inactive_threshold || app_count > kMaxEphemeralAppsCount) { |
| 222 remove_app_ids->insert(it->second); | 222 remove_app_ids->insert(it->second); |
| 223 --app_count; | 223 --app_count; |
| 224 } else { | 224 } else { |
| 225 break; | 225 break; |
| 226 } | 226 } |
| 227 } | 227 } |
| 228 } | 228 } |
| OLD | NEW |