OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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/extensions_service.h" | 5 #include "chrome/browser/extensions/extensions_service.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 | 8 |
9 #include "base/basictypes.h" | 9 #include "base/basictypes.h" |
10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
(...skipping 594 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
605 } | 605 } |
606 } | 606 } |
607 | 607 |
608 void ExtensionsService::InitEventRouters() { | 608 void ExtensionsService::InitEventRouters() { |
609 if (event_routers_initialized_) | 609 if (event_routers_initialized_) |
610 return; | 610 return; |
611 | 611 |
612 ExtensionHistoryEventRouter::GetInstance()->ObserveProfile(profile_); | 612 ExtensionHistoryEventRouter::GetInstance()->ObserveProfile(profile_); |
613 ExtensionAccessibilityEventRouter::GetInstance()->ObserveProfile(profile_); | 613 ExtensionAccessibilityEventRouter::GetInstance()->ObserveProfile(profile_); |
614 ExtensionBrowserEventRouter::GetInstance()->Init(profile_); | 614 ExtensionBrowserEventRouter::GetInstance()->Init(profile_); |
615 ExtensionBookmarkEventRouter::GetSingleton()->Observe( | 615 ExtensionBookmarkEventRouter::GetInstance()->Observe( |
616 profile_->GetBookmarkModel()); | 616 profile_->GetBookmarkModel()); |
617 ExtensionCookiesEventRouter::GetInstance()->Init(); | 617 ExtensionCookiesEventRouter::GetInstance()->Init(); |
618 ExtensionManagementEventRouter::GetInstance()->Init(); | 618 ExtensionManagementEventRouter::GetInstance()->Init(); |
619 ExtensionProcessesEventRouter::GetInstance()->ObserveProfile(profile_); | 619 ExtensionProcessesEventRouter::GetInstance()->ObserveProfile(profile_); |
620 ExtensionWebNavigationEventRouter::GetInstance()->Init(); | 620 ExtensionWebNavigationEventRouter::GetInstance()->Init(); |
621 event_routers_initialized_ = true; | 621 event_routers_initialized_ = true; |
622 } | 622 } |
623 | 623 |
624 const Extension* ExtensionsService::GetExtensionById(const std::string& id, | 624 const Extension* ExtensionsService::GetExtensionById(const std::string& id, |
625 bool include_disabled) { | 625 bool include_disabled) { |
(...skipping 1460 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2086 } | 2086 } |
2087 | 2087 |
2088 void ExtensionsService::SetBeingUpgraded(const Extension* extension, | 2088 void ExtensionsService::SetBeingUpgraded(const Extension* extension, |
2089 bool value) { | 2089 bool value) { |
2090 extension_runtime_data_[extension->id()].being_upgraded = value; | 2090 extension_runtime_data_[extension->id()].being_upgraded = value; |
2091 } | 2091 } |
2092 | 2092 |
2093 PropertyBag* ExtensionsService::GetPropertyBag(const Extension* extension) { | 2093 PropertyBag* ExtensionsService::GetPropertyBag(const Extension* extension) { |
2094 return &extension_runtime_data_[extension->id()].property_bag; | 2094 return &extension_runtime_data_[extension->id()].property_bag; |
2095 } | 2095 } |
OLD | NEW |