Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(107)

Side by Side Diff: chrome/browser/extensions/extension_error_controller.cc

Issue 384423002: [Canceled] Extensions: Add install_flags parameter to ManagementPolicy::UserMayLoad (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: update tests Created 6 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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_error_controller.h" 5 #include "chrome/browser/extensions/extension_error_controller.h"
6 6
7 #include "chrome/browser/extensions/extension_service.h" 7 #include "chrome/browser/extensions/extension_service.h"
8 #include "chrome/browser/extensions/pending_extension_manager.h" 8 #include "chrome/browser/extensions/pending_extension_manager.h"
9 #include "extensions/browser/extension_prefs.h" 9 #include "extensions/browser/extension_prefs.h"
10 #include "extensions/browser/extension_registry.h" 10 #include "extensions/browser/extension_registry.h"
(...skipping 110 matching lines...) Expand 10 before | Expand all | Expand 10 after
121 ++iter) { 121 ++iter) {
122 const Extension* extension = *iter; 122 const Extension* extension = *iter;
123 123
124 // Skip for extensions that have pending updates. They will be checked again 124 // Skip for extensions that have pending updates. They will be checked again
125 // once the pending update is finished. 125 // once the pending update is finished.
126 if (pending_extension_manager->IsIdPending(extension->id())) 126 if (pending_extension_manager->IsIdPending(extension->id()))
127 continue; 127 continue;
128 128
129 // Extensions disabled by policy. Note: this no longer includes blacklisted 129 // Extensions disabled by policy. Note: this no longer includes blacklisted
130 // extensions, though we still show the same UI. 130 // extensions, though we still show the same UI.
131 if (!management_policy->UserMayLoad(extension, NULL /* ignore error */)) { 131 int install_flags = prefs->GetInstallFlags(extension->id());
132 if (!management_policy->UserMayLoad(
133 extension, install_flags, NULL /* ignore error */)) {
132 if (!prefs->IsBlacklistedExtensionAcknowledged(extension->id())) 134 if (!prefs->IsBlacklistedExtensionAcknowledged(extension->id()))
133 blacklisted_extensions_.Insert(extension); 135 blacklisted_extensions_.Insert(extension);
134 } 136 }
135 } 137 }
136 } 138 }
137 139
138 } // namespace extensions 140 } // namespace extensions
OLDNEW
« no previous file with comments | « chrome/browser/extensions/crx_installer_browsertest.cc ('k') | chrome/browser/extensions/extension_install_checker.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698