| OLD | NEW |
| 1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2006-2008 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 "base/compiler_specific.h" | 5 #include "base/compiler_specific.h" |
| 6 #include "build/build_config.h" | 6 #include "build/build_config.h" |
| 7 | 7 |
| 8 #if defined(OS_WIN) | 8 #if defined(OS_WIN) |
| 9 #include <objidl.h> | 9 #include <objidl.h> |
| 10 #include <mlang.h> | 10 #include <mlang.h> |
| (...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 57 // Global variable used by the plugin quirk "die after unload". | 57 // Global variable used by the plugin quirk "die after unload". |
| 58 bool g_forcefully_terminate_plugin_process = false; | 58 bool g_forcefully_terminate_plugin_process = false; |
| 59 | 59 |
| 60 void SetJavaScriptFlags(const std::wstring& str) { | 60 void SetJavaScriptFlags(const std::wstring& str) { |
| 61 #if USE(V8) | 61 #if USE(V8) |
| 62 std::string utf8_str = WideToUTF8(str); | 62 std::string utf8_str = WideToUTF8(str); |
| 63 WebCore::ScriptController::setFlags(utf8_str.data(), static_cast<int>(utf8_str
.size())); | 63 WebCore::ScriptController::setFlags(utf8_str.data(), static_cast<int>(utf8_str
.size())); |
| 64 #endif | 64 #endif |
| 65 } | 65 } |
| 66 | 66 |
| 67 void SetRecordPlaybackMode(bool value) { | |
| 68 #if USE(V8) | |
| 69 WebCore::ScriptController::setRecordPlaybackMode(value); | |
| 70 #endif | |
| 71 } | |
| 72 | |
| 73 void SetShouldExposeGCController(bool enable) { | |
| 74 #if USE(V8) | |
| 75 WebCore::ScriptController::setShouldExposeGCController(enable); | |
| 76 #endif | |
| 77 } | |
| 78 | |
| 79 void EnableWebCoreNotImplementedLogging() { | 67 void EnableWebCoreNotImplementedLogging() { |
| 80 WebCore::LogNotYetImplemented.state = WTFLogChannelOn; | 68 WebCore::LogNotYetImplemented.state = WTFLogChannelOn; |
| 81 } | 69 } |
| 82 | 70 |
| 83 std::wstring DumpDocumentText(WebFrame* web_frame) { | 71 std::wstring DumpDocumentText(WebFrame* web_frame) { |
| 84 WebFrameImpl* webFrameImpl = static_cast<WebFrameImpl*>(web_frame); | 72 WebFrameImpl* webFrameImpl = static_cast<WebFrameImpl*>(web_frame); |
| 85 WebCore::Frame* frame = webFrameImpl->frame(); | 73 WebCore::Frame* frame = webFrameImpl->frame(); |
| 86 | 74 |
| 87 // We use the document element's text instead of the body text here because | 75 // We use the document element's text instead of the body text here because |
| 88 // not all documents have a body, such as XML documents. | 76 // not all documents have a body, such as XML documents. |
| (...skipping 345 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 434 } | 422 } |
| 435 | 423 |
| 436 g_forcefully_terminate_plugin_process = value; | 424 g_forcefully_terminate_plugin_process = value; |
| 437 } | 425 } |
| 438 | 426 |
| 439 bool ShouldForcefullyTerminatePluginProcess() { | 427 bool ShouldForcefullyTerminatePluginProcess() { |
| 440 return g_forcefully_terminate_plugin_process; | 428 return g_forcefully_terminate_plugin_process; |
| 441 } | 429 } |
| 442 | 430 |
| 443 } // namespace webkit_glue | 431 } // namespace webkit_glue |
| OLD | NEW |