| 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 <set> | 8 #include <set> |
| 9 | 9 |
| 10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
| (...skipping 499 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 510 input_method_event_router_.reset( | 510 input_method_event_router_.reset( |
| 511 new chromeos::ExtensionInputMethodEventRouter); | 511 new chromeos::ExtensionInputMethodEventRouter); |
| 512 | 512 |
| 513 ExtensionMediaPlayerEventRouter::GetInstance()->Init(profile_); | 513 ExtensionMediaPlayerEventRouter::GetInstance()->Init(profile_); |
| 514 extensions::InputImeEventRouter::GetInstance()->Init(); | 514 extensions::InputImeEventRouter::GetInstance()->Init(); |
| 515 #endif | 515 #endif |
| 516 #endif // defined(ENABLE_EXTENSIONS) | 516 #endif // defined(ENABLE_EXTENSIONS) |
| 517 event_routers_initialized_ = true; | 517 event_routers_initialized_ = true; |
| 518 } | 518 } |
| 519 | 519 |
| 520 void ExtensionService::Shutdown() { |
| 521 push_messaging_event_router_->Shutdown(); |
| 522 } |
| 523 |
| 520 const Extension* ExtensionService::GetExtensionById( | 524 const Extension* ExtensionService::GetExtensionById( |
| 521 const std::string& id, bool include_disabled) const { | 525 const std::string& id, bool include_disabled) const { |
| 522 int include_mask = INCLUDE_ENABLED; | 526 int include_mask = INCLUDE_ENABLED; |
| 523 if (include_disabled) { | 527 if (include_disabled) { |
| 524 include_mask |= INCLUDE_DISABLED; | 528 include_mask |= INCLUDE_DISABLED; |
| 525 } | 529 } |
| 526 return GetExtensionByIdInternal(id, include_mask); | 530 return GetExtensionByIdInternal(id, include_mask); |
| 527 } | 531 } |
| 528 | 532 |
| 529 void ExtensionService::Init() { | 533 void ExtensionService::Init() { |
| (...skipping 2023 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2553 | 2557 |
| 2554 ExtensionService::NaClModuleInfoList::iterator | 2558 ExtensionService::NaClModuleInfoList::iterator |
| 2555 ExtensionService::FindNaClModule(const GURL& url) { | 2559 ExtensionService::FindNaClModule(const GURL& url) { |
| 2556 for (NaClModuleInfoList::iterator iter = nacl_module_list_.begin(); | 2560 for (NaClModuleInfoList::iterator iter = nacl_module_list_.begin(); |
| 2557 iter != nacl_module_list_.end(); ++iter) { | 2561 iter != nacl_module_list_.end(); ++iter) { |
| 2558 if (iter->url == url) | 2562 if (iter->url == url) |
| 2559 return iter; | 2563 return iter; |
| 2560 } | 2564 } |
| 2561 return nacl_module_list_.end(); | 2565 return nacl_module_list_.end(); |
| 2562 } | 2566 } |
| OLD | NEW |