| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 <set> | 8 #include <set> |
| 9 | 9 |
| 10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
| (...skipping 532 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 543 const Extension* extension = | 543 const Extension* extension = |
| 544 GetExtensionByIdInternal(id, true, true, false); | 544 GetExtensionByIdInternal(id, true, true, false); |
| 545 if (!is_pending_extension && !extension) { | 545 if (!is_pending_extension && !extension) { |
| 546 LOG(WARNING) << "Will not update extension " << id | 546 LOG(WARNING) << "Will not update extension " << id |
| 547 << " because it is not installed or pending"; | 547 << " because it is not installed or pending"; |
| 548 // Delete extension_path since we're not creating a CrxInstaller | 548 // Delete extension_path since we're not creating a CrxInstaller |
| 549 // that would do it for us. | 549 // that would do it for us. |
| 550 if (!BrowserThread::PostTask( | 550 if (!BrowserThread::PostTask( |
| 551 BrowserThread::FILE, FROM_HERE, | 551 BrowserThread::FILE, FROM_HERE, |
| 552 base::Bind( | 552 base::Bind( |
| 553 extension_file_util::DeleteFile, extension_path, false))) | 553 &extension_file_util::DeleteFile, extension_path, false))) |
| 554 NOTREACHED(); | 554 NOTREACHED(); |
| 555 | 555 |
| 556 return false; | 556 return false; |
| 557 } | 557 } |
| 558 | 558 |
| 559 // We want a silent install only for non-pending extensions and | 559 // We want a silent install only for non-pending extensions and |
| 560 // pending extensions that have install_silently set. | 560 // pending extensions that have install_silently set. |
| 561 ExtensionInstallUI* client = | 561 ExtensionInstallUI* client = |
| 562 (!is_pending_extension || pending_extension_info.install_silently()) ? | 562 (!is_pending_extension || pending_extension_info.install_silently()) ? |
| 563 NULL : new ExtensionInstallUI(profile_); | 563 NULL : new ExtensionInstallUI(profile_); |
| (...skipping 1926 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2490 | 2490 |
| 2491 ExtensionService::NaClModuleInfoList::iterator | 2491 ExtensionService::NaClModuleInfoList::iterator |
| 2492 ExtensionService::FindNaClModule(const GURL& url) { | 2492 ExtensionService::FindNaClModule(const GURL& url) { |
| 2493 for (NaClModuleInfoList::iterator iter = nacl_module_list_.begin(); | 2493 for (NaClModuleInfoList::iterator iter = nacl_module_list_.begin(); |
| 2494 iter != nacl_module_list_.end(); ++iter) { | 2494 iter != nacl_module_list_.end(); ++iter) { |
| 2495 if (iter->url == url) | 2495 if (iter->url == url) |
| 2496 return iter; | 2496 return iter; |
| 2497 } | 2497 } |
| 2498 return nacl_module_list_.end(); | 2498 return nacl_module_list_.end(); |
| 2499 } | 2499 } |
| OLD | NEW |