| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 "extensions/shell/browser/shell_extensions_browser_client.h" | 5 #include "extensions/shell/browser/shell_extensions_browser_client.h" |
| 6 | 6 |
| 7 #include "content/public/browser/browser_thread.h" | 7 #include "content/public/browser/browser_thread.h" |
| 8 #include "extensions/browser/api/extensions_api_client.h" | 8 #include "extensions/browser/api/extensions_api_client.h" |
| 9 #include "extensions/browser/api/generated_api_registration.h" | 9 #include "extensions/browser/api/generated_api_registration.h" |
| 10 #include "extensions/browser/app_sorting.h" | 10 #include "extensions/browser/app_sorting.h" |
| (...skipping 157 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 168 // app_shell-only APIs. | 168 // app_shell-only APIs. |
| 169 shell::api::GeneratedFunctionRegistry::RegisterAll(registry); | 169 shell::api::GeneratedFunctionRegistry::RegisterAll(registry); |
| 170 } | 170 } |
| 171 | 171 |
| 172 scoped_ptr<RuntimeAPIDelegate> | 172 scoped_ptr<RuntimeAPIDelegate> |
| 173 ShellExtensionsBrowserClient::CreateRuntimeAPIDelegate( | 173 ShellExtensionsBrowserClient::CreateRuntimeAPIDelegate( |
| 174 content::BrowserContext* context) const { | 174 content::BrowserContext* context) const { |
| 175 return scoped_ptr<RuntimeAPIDelegate>(new ShellRuntimeAPIDelegate()); | 175 return scoped_ptr<RuntimeAPIDelegate>(new ShellRuntimeAPIDelegate()); |
| 176 } | 176 } |
| 177 | 177 |
| 178 ComponentExtensionResourceManager* | 178 const ComponentExtensionResourceManager* |
| 179 ShellExtensionsBrowserClient::GetComponentExtensionResourceManager() { | 179 ShellExtensionsBrowserClient::GetComponentExtensionResourceManager() { |
| 180 return NULL; | 180 return NULL; |
| 181 } | 181 } |
| 182 | 182 |
| 183 void ShellExtensionsBrowserClient::BroadcastEventToRenderers( | 183 void ShellExtensionsBrowserClient::BroadcastEventToRenderers( |
| 184 const std::string& event_name, | 184 const std::string& event_name, |
| 185 scoped_ptr<base::ListValue> args) { | 185 scoped_ptr<base::ListValue> args) { |
| 186 if (!BrowserThread::CurrentlyOn(BrowserThread::UI)) { | 186 if (!BrowserThread::CurrentlyOn(BrowserThread::UI)) { |
| 187 BrowserThread::PostTask( | 187 BrowserThread::PostTask( |
| 188 BrowserThread::UI, | 188 BrowserThread::UI, |
| (...skipping 25 matching lines...) Expand all Loading... |
| 214 const std::string& min_version) { | 214 const std::string& min_version) { |
| 215 return true; | 215 return true; |
| 216 } | 216 } |
| 217 | 217 |
| 218 void ShellExtensionsBrowserClient::SetAPIClientForTest( | 218 void ShellExtensionsBrowserClient::SetAPIClientForTest( |
| 219 ExtensionsAPIClient* api_client) { | 219 ExtensionsAPIClient* api_client) { |
| 220 api_client_.reset(api_client); | 220 api_client_.reset(api_client); |
| 221 } | 221 } |
| 222 | 222 |
| 223 } // namespace extensions | 223 } // namespace extensions |
| OLD | NEW |