| 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/extension_function_dispatcher.h" | 5 #include "chrome/browser/extensions/extension_function_dispatcher.h" |
| 6 | 6 |
| 7 #include <map> |
| 8 |
| 7 #include "base/process_util.h" | 9 #include "base/process_util.h" |
| 8 #include "base/singleton.h" | 10 #include "base/singleton.h" |
| 9 #include "base/ref_counted.h" | 11 #include "base/ref_counted.h" |
| 10 #include "base/values.h" | 12 #include "base/values.h" |
| 11 #include "build/build_config.h" | 13 #include "build/build_config.h" |
| 12 #include "chrome/browser/browser_list.h" | 14 #include "chrome/browser/browser_list.h" |
| 13 #include "chrome/browser/browser_window.h" | 15 #include "chrome/browser/browser_window.h" |
| 14 #include "chrome/browser/dom_ui/chrome_url_data_manager.h" | 16 #include "chrome/browser/dom_ui/chrome_url_data_manager.h" |
| 15 #include "chrome/browser/dom_ui/dom_ui_favicon_source.h" | 17 #include "chrome/browser/dom_ui/dom_ui_favicon_source.h" |
| 16 #include "chrome/browser/external_protocol_handler.h" | 18 #include "chrome/browser/external_protocol_handler.h" |
| (...skipping 198 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 215 RegisterFunction<SetCookieFunction>(); | 217 RegisterFunction<SetCookieFunction>(); |
| 216 RegisterFunction<RemoveCookieFunction>(); | 218 RegisterFunction<RemoveCookieFunction>(); |
| 217 RegisterFunction<GetAllCookieStoresFunction>(); | 219 RegisterFunction<GetAllCookieStoresFunction>(); |
| 218 | 220 |
| 219 // Test. | 221 // Test. |
| 220 RegisterFunction<ExtensionTestPassFunction>(); | 222 RegisterFunction<ExtensionTestPassFunction>(); |
| 221 RegisterFunction<ExtensionTestFailFunction>(); | 223 RegisterFunction<ExtensionTestFailFunction>(); |
| 222 RegisterFunction<ExtensionTestLogFunction>(); | 224 RegisterFunction<ExtensionTestLogFunction>(); |
| 223 RegisterFunction<ExtensionTestQuotaResetFunction>(); | 225 RegisterFunction<ExtensionTestQuotaResetFunction>(); |
| 224 RegisterFunction<ExtensionTestCreateIncognitoTabFunction>(); | 226 RegisterFunction<ExtensionTestCreateIncognitoTabFunction>(); |
| 227 RegisterFunction<ExtensionTestSendMessageFunction>(); |
| 225 | 228 |
| 226 // Accessibility. | 229 // Accessibility. |
| 227 RegisterFunction<GetFocusedControlFunction>(); | 230 RegisterFunction<GetFocusedControlFunction>(); |
| 228 RegisterFunction<SetAccessibilityEnabledFunction>(); | 231 RegisterFunction<SetAccessibilityEnabledFunction>(); |
| 229 | 232 |
| 230 // Clipboard. | 233 // Clipboard. |
| 231 RegisterFunction<ExecuteCopyClipboardFunction>(); | 234 RegisterFunction<ExecuteCopyClipboardFunction>(); |
| 232 RegisterFunction<ExecuteCutClipboardFunction>(); | 235 RegisterFunction<ExecuteCutClipboardFunction>(); |
| 233 RegisterFunction<ExecutePasteClipboardFunction>(); | 236 RegisterFunction<ExecutePasteClipboardFunction>(); |
| 234 | 237 |
| (...skipping 204 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 439 } else { | 442 } else { |
| 440 NOTREACHED(); | 443 NOTREACHED(); |
| 441 base::KillProcess(render_view_host_->process()->GetHandle(), | 444 base::KillProcess(render_view_host_->process()->GetHandle(), |
| 442 ResultCodes::KILLED_BAD_MESSAGE, false); | 445 ResultCodes::KILLED_BAD_MESSAGE, false); |
| 443 } | 446 } |
| 444 } | 447 } |
| 445 | 448 |
| 446 Profile* ExtensionFunctionDispatcher::profile() { | 449 Profile* ExtensionFunctionDispatcher::profile() { |
| 447 return profile_; | 450 return profile_; |
| 448 } | 451 } |
| OLD | NEW |