Resubmit of Remove AppIsolation from Extension Class
Previous patch was reverted. Problem has been fixed (see comment in CL).
Original CL here: https://codereview.chromium.org/12770031/
[email protected], [email protected]
(ben - gypis, joi - public/browser/ comment update)
BUG=159265
Review URL: https://chromiumcodereview.appspot.com/13393015
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@192007 0039d316-1c4b-4281-b951-d872f2087c98
diff --git a/chrome/browser/extensions/extension_service.cc b/chrome/browser/extensions/extension_service.cc
index 63c35b27..e7d3def 100644
--- a/chrome/browser/extensions/extension_service.cc
+++ b/chrome/browser/extensions/extension_service.cc
@@ -87,6 +87,7 @@
#include "chrome/common/extensions/features/feature.h"
#include "chrome/common/extensions/incognito_handler.h"
#include "chrome/common/extensions/manifest.h"
+#include "chrome/common/extensions/manifest_handlers/app_isolation_info.h"
#include "chrome/common/extensions/manifest_url_handler.h"
#include "chrome/common/pref_names.h"
#include "chrome/common/startup_metric_utils.h"
@@ -293,10 +294,11 @@
const extensions::Extension* extension =
extensions_.GetByID(*(extension_ids.begin()));
- // We still need to check is_storage_isolated(),
+ // We still need to check if the extension has isolated storage,
// because it's common for there to be one extension in a process
- // with is_storage_isolated() == false.
- if (extension && extension->is_storage_isolated())
+ // without isolated storage.
+ if (extension &&
+ extensions::AppIsolationInfo::HasIsolatedStorage(extension))
return extension;
return NULL;
@@ -845,7 +847,8 @@
GURL launch_web_url_origin(extension->launch_web_url());
launch_web_url_origin = launch_web_url_origin.GetOrigin();
- bool is_storage_isolated = extension->is_storage_isolated();
+ bool is_storage_isolated =
+ extensions::AppIsolationInfo::HasIsolatedStorage(extension);
if (is_storage_isolated) {
BrowserContext::AsyncObliterateStoragePartition(
@@ -3051,7 +3054,7 @@
new base::hash_set<base::FilePath>());
for (ExtensionSet::const_iterator it = extensions_.begin();
it != extensions_.end(); ++it) {
- if ((*it)->is_storage_isolated()) {
+ if (extensions::AppIsolationInfo::HasIsolatedStorage(*it)) {
active_paths->insert(
BrowserContext::GetStoragePartitionForSite(
profile_,