| 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/extensions/extension_service.h" | 5 #include "chrome/browser/extensions/extension_service.h" | 
| 6 | 6 | 
| 7 #include <algorithm> | 7 #include <algorithm> | 
| 8 #include <iterator> | 8 #include <iterator> | 
| 9 #include <set> | 9 #include <set> | 
| 10 | 10 | 
| (...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 72 #include "chrome/browser/themes/theme_service.h" | 72 #include "chrome/browser/themes/theme_service.h" | 
| 73 #include "chrome/browser/themes/theme_service_factory.h" | 73 #include "chrome/browser/themes/theme_service_factory.h" | 
| 74 #include "chrome/browser/ui/webui/favicon_source.h" | 74 #include "chrome/browser/ui/webui/favicon_source.h" | 
| 75 #include "chrome/browser/ui/webui/ntp/thumbnail_source.h" | 75 #include "chrome/browser/ui/webui/ntp/thumbnail_source.h" | 
| 76 #include "chrome/browser/ui/webui/theme_source.h" | 76 #include "chrome/browser/ui/webui/theme_source.h" | 
| 77 #include "chrome/common/child_process_logging.h" | 77 #include "chrome/common/child_process_logging.h" | 
| 78 #include "chrome/common/chrome_notification_types.h" | 78 #include "chrome/common/chrome_notification_types.h" | 
| 79 #include "chrome/common/chrome_paths.h" | 79 #include "chrome/common/chrome_paths.h" | 
| 80 #include "chrome/common/chrome_switches.h" | 80 #include "chrome/common/chrome_switches.h" | 
| 81 #include "chrome/common/chrome_version_info.h" | 81 #include "chrome/common/chrome_version_info.h" | 
|  | 82 #include "chrome/common/extensions/app_launch_manifest_handler.h" | 
| 82 #include "chrome/common/extensions/extension.h" | 83 #include "chrome/common/extensions/extension.h" | 
| 83 #include "chrome/common/extensions/extension_file_util.h" | 84 #include "chrome/common/extensions/extension_file_util.h" | 
| 84 #include "chrome/common/extensions/extension_manifest_constants.h" | 85 #include "chrome/common/extensions/extension_manifest_constants.h" | 
| 85 #include "chrome/common/extensions/extension_messages.h" | 86 #include "chrome/common/extensions/extension_messages.h" | 
| 86 #include "chrome/common/extensions/extension_resource.h" | 87 #include "chrome/common/extensions/extension_resource.h" | 
| 87 #include "chrome/common/extensions/feature_switch.h" | 88 #include "chrome/common/extensions/feature_switch.h" | 
| 88 #include "chrome/common/extensions/features/feature.h" | 89 #include "chrome/common/extensions/features/feature.h" | 
| 89 #include "chrome/common/extensions/manifest_url_handler.h" | 90 #include "chrome/common/extensions/manifest_url_handler.h" | 
| 90 #include "chrome/common/pref_names.h" | 91 #include "chrome/common/pref_names.h" | 
| 91 #include "chrome/common/startup_metric_utils.h" | 92 #include "chrome/common/startup_metric_utils.h" | 
| (...skipping 731 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 823   if (Manifest::LOAD != extension->location()) { | 824   if (Manifest::LOAD != extension->location()) { | 
| 824     if (!GetFileTaskRunner()->PostTask( | 825     if (!GetFileTaskRunner()->PostTask( | 
| 825             FROM_HERE, | 826             FROM_HERE, | 
| 826             base::Bind( | 827             base::Bind( | 
| 827                 &extension_file_util::UninstallExtension, | 828                 &extension_file_util::UninstallExtension, | 
| 828                 install_directory_, | 829                 install_directory_, | 
| 829                 extension_id))) | 830                 extension_id))) | 
| 830       NOTREACHED(); | 831       NOTREACHED(); | 
| 831   } | 832   } | 
| 832 | 833 | 
| 833   GURL launch_web_url_origin(extension->launch_web_url()); | 834   GURL launch_web_url_origin( | 
|  | 835       extensions::AppLaunchInfo::GetLaunchWebUrl(extension)); | 
| 834   launch_web_url_origin = launch_web_url_origin.GetOrigin(); | 836   launch_web_url_origin = launch_web_url_origin.GetOrigin(); | 
| 835   bool is_storage_isolated = extension->is_storage_isolated(); | 837   bool is_storage_isolated = extension->is_storage_isolated(); | 
| 836 | 838 | 
| 837   if (is_storage_isolated) { | 839   if (is_storage_isolated) { | 
| 838     BrowserContext::AsyncObliterateStoragePartition( | 840     BrowserContext::AsyncObliterateStoragePartition( | 
| 839         profile_, | 841         profile_, | 
| 840         GetSiteForExtensionId(extension_id), | 842         GetSiteForExtensionId(extension_id), | 
| 841         base::Bind(&ExtensionService::OnNeedsToGarbageCollectIsolatedStorage, | 843         base::Bind(&ExtensionService::OnNeedsToGarbageCollectIsolatedStorage, | 
| 842                    AsWeakPtr())); | 844                    AsWeakPtr())); | 
| 843   } else { | 845   } else { | 
| (...skipping 2263 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 3107     scoped_refptr<const Extension> extension = GetInstalledExtension(*it); | 3109     scoped_refptr<const Extension> extension = GetInstalledExtension(*it); | 
| 3108     DCHECK(extension); | 3110     DCHECK(extension); | 
| 3109     if (!extension) | 3111     if (!extension) | 
| 3110       continue; | 3112       continue; | 
| 3111     blacklisted_extensions_.Insert(extension); | 3113     blacklisted_extensions_.Insert(extension); | 
| 3112     UnloadExtension(*it, extension_misc::UNLOAD_REASON_BLACKLIST); | 3114     UnloadExtension(*it, extension_misc::UNLOAD_REASON_BLACKLIST); | 
| 3113   } | 3115   } | 
| 3114 | 3116 | 
| 3115   IdentifyAlertableExtensions(); | 3117   IdentifyAlertableExtensions(); | 
| 3116 } | 3118 } | 
| OLD | NEW | 
|---|