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 2442 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2453 } | 2453 } |
2454 | 2454 |
2455 // Certain extension locations are specific enough that we can | 2455 // Certain extension locations are specific enough that we can |
2456 // auto-acknowledge any extension that came from one of them. | 2456 // auto-acknowledge any extension that came from one of them. |
2457 if (extension->location() == Extension::EXTERNAL_POLICY_DOWNLOAD) | 2457 if (extension->location() == Extension::EXTERNAL_POLICY_DOWNLOAD) |
2458 AcknowledgeExternalExtension(extension->id()); | 2458 AcknowledgeExternalExtension(extension->id()); |
2459 | 2459 |
2460 if (ShouldDelayExtensionUpdate(id, wait_for_idle)) { | 2460 if (ShouldDelayExtensionUpdate(id, wait_for_idle)) { |
2461 extension_prefs_->SetIdleInstallInfo( | 2461 extension_prefs_->SetIdleInstallInfo( |
2462 extension, | 2462 extension, |
2463 initial_enable ? Extension::ENABLED : Extension::DISABLED); | 2463 initial_enable ? Extension::ENABLED : Extension::DISABLED, |
| 2464 page_ordinal); |
2464 | 2465 |
2465 // Transfer ownership of |extension|. | 2466 // Transfer ownership of |extension|. |
2466 pending_extension_updates_.Insert(extension); | 2467 pending_extension_updates_.Insert(extension); |
2467 | 2468 |
2468 // Notify extension of available update. | 2469 // Notify extension of available update. |
2469 extensions::RuntimeEventRouter::DispatchOnUpdateAvailableEvent( | 2470 extensions::RuntimeEventRouter::DispatchOnUpdateAvailableEvent( |
2470 profile_, id, extension->manifest()->value()); | 2471 profile_, id, extension->manifest()->value()); |
2471 return; | 2472 return; |
2472 } | 2473 } |
2473 | 2474 |
(...skipping 647 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3121 scoped_refptr<const Extension> extension = GetInstalledExtension(*it); | 3122 scoped_refptr<const Extension> extension = GetInstalledExtension(*it); |
3122 DCHECK(extension); | 3123 DCHECK(extension); |
3123 if (!extension) | 3124 if (!extension) |
3124 continue; | 3125 continue; |
3125 blacklisted_extensions_.Insert(extension); | 3126 blacklisted_extensions_.Insert(extension); |
3126 UnloadExtension(*it, extension_misc::UNLOAD_REASON_BLACKLIST); | 3127 UnloadExtension(*it, extension_misc::UNLOAD_REASON_BLACKLIST); |
3127 } | 3128 } |
3128 | 3129 |
3129 IdentifyAlertableExtensions(); | 3130 IdentifyAlertableExtensions(); |
3130 } | 3131 } |
OLD | NEW |