summaryrefslogtreecommitdiffstats
path: root/chrome/browser/extensions/extension_commands_global_registry.cc
diff options
context:
space:
mode:
authoryoz@chromium.org <yoz@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-02-25 19:24:41 +0000
committeryoz@chromium.org <yoz@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-02-25 19:24:41 +0000
commitc4b717a7763a8509b525ecbcf1d0f03d7eed83b6 (patch)
tree4b5064226e2dbde8a0459dc4cc4989f9c140775a /chrome/browser/extensions/extension_commands_global_registry.cc
parent8548c45dc44afeaeaca0044ec9004aa98a16e754 (diff)
downloadchromium_src-c4b717a7763a8509b525ecbcf1d0f03d7eed83b6.zip
chromium_src-c4b717a7763a8509b525ecbcf1d0f03d7eed83b6.tar.gz
chromium_src-c4b717a7763a8509b525ecbcf1d0f03d7eed83b6.tar.bz2
Move ProfileKeyedAPI implementations to take BrowserContext in the constructor (part 3).
This is the last part. Follows part 1: https://chromiumcodereview.appspot.com/171813010/ BUG=309909 R=jamescook@chromium.org TBR=brettw@chromium.org, dtseng@chromium.org, erg@chromium.org Review URL: https://codereview.chromium.org/174513003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@253223 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/extensions/extension_commands_global_registry.cc')
-rw-r--r--chrome/browser/extensions/extension_commands_global_registry.cc20
1 files changed, 10 insertions, 10 deletions
diff --git a/chrome/browser/extensions/extension_commands_global_registry.cc b/chrome/browser/extensions/extension_commands_global_registry.cc
index 24c5b7e..17b4da0 100644
--- a/chrome/browser/extensions/extension_commands_global_registry.cc
+++ b/chrome/browser/extensions/extension_commands_global_registry.cc
@@ -7,16 +7,16 @@
#include "base/lazy_instance.h"
#include "chrome/browser/extensions/api/commands/command_service.h"
#include "chrome/browser/extensions/global_shortcut_listener.h"
-#include "chrome/browser/profiles/profile.h"
#include "extensions/common/extension.h"
namespace extensions {
ExtensionCommandsGlobalRegistry::ExtensionCommandsGlobalRegistry(
- Profile* profile)
- : ExtensionKeybindingRegistry(
- profile, ExtensionKeybindingRegistry::ALL_EXTENSIONS, NULL),
- profile_(profile) {
+ content::BrowserContext* context)
+ : ExtensionKeybindingRegistry(context,
+ ExtensionKeybindingRegistry::ALL_EXTENSIONS,
+ NULL),
+ browser_context_(context) {
Init();
}
@@ -39,10 +39,10 @@ ExtensionCommandsGlobalRegistry::GetFactoryInstance() {
}
// static
-ExtensionCommandsGlobalRegistry*
-ExtensionCommandsGlobalRegistry::Get(Profile* profile) {
- return ProfileKeyedAPIFactory<
- ExtensionCommandsGlobalRegistry>::GetForProfile(profile);
+ExtensionCommandsGlobalRegistry* ExtensionCommandsGlobalRegistry::Get(
+ content::BrowserContext* context) {
+ return ProfileKeyedAPIFactory<ExtensionCommandsGlobalRegistry>::GetForProfile(
+ context);
}
void ExtensionCommandsGlobalRegistry::AddExtensionKeybinding(
@@ -53,7 +53,7 @@ void ExtensionCommandsGlobalRegistry::AddExtensionKeybinding(
return;
extensions::CommandService* command_service =
- extensions::CommandService::Get(profile_);
+ extensions::CommandService::Get(browser_context_);
// Add all the active global keybindings, if any.
extensions::CommandMap commands;
if (!command_service->GetNamedCommands(