| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2010 Google Inc. All rights reserved. | 2 * Copyright (C) 2010 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
| 6 * met: | 6 * met: |
| 7 * | 7 * |
| 8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 14 matching lines...) Expand all Loading... |
| 25 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY | 25 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY |
| 26 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT | 26 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT |
| 27 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE | 27 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE |
| 28 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 28 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
| 29 */ | 29 */ |
| 30 | 30 |
| 31 #include "config.h" | 31 #include "config.h" |
| 32 #include "WebDevToolsFrontendImpl.h" | 32 #include "WebDevToolsFrontendImpl.h" |
| 33 | 33 |
| 34 #include "ContextMenuController.h" | 34 #include "ContextMenuController.h" |
| 35 #include "ContextMenuItem.h" | |
| 36 #include "DOMWindow.h" | 35 #include "DOMWindow.h" |
| 37 #include "Document.h" | 36 #include "Document.h" |
| 38 #include "Event.h" | 37 #include "Event.h" |
| 39 #include "Frame.h" | 38 #include "Frame.h" |
| 40 #include "InspectorController.h" | 39 #include "InspectorController.h" |
| 41 #include "InspectorFrontendClientImpl.h" | 40 #include "InspectorFrontendClientImpl.h" |
| 42 #include "InspectorFrontendHost.h" | 41 #include "InspectorFrontendHost.h" |
| 43 #include "Node.h" | 42 #include "Node.h" |
| 44 #include "Page.h" | 43 #include "Page.h" |
| 45 #include "Pasteboard.h" | |
| 46 #include "ScriptController.h" | 44 #include "ScriptController.h" |
| 47 #include "SecurityOrigin.h" | 45 #include "SecurityOrigin.h" |
| 48 #include "Settings.h" | 46 #include "Settings.h" |
| 49 #include "V8Binding.h" | 47 #include "V8Binding.h" |
| 50 #include "V8DOMWrapper.h" | 48 #include "V8DOMWrapper.h" |
| 51 #include "V8InspectorFrontendHost.h" | 49 #include "V8InspectorFrontendHost.h" |
| 52 #include "V8MouseEvent.h" | 50 #include "V8MouseEvent.h" |
| 53 #include "V8Node.h" | 51 #include "V8Node.h" |
| 54 #include "V8Utilities.h" | 52 #include "V8Utilities.h" |
| 55 #include "WebDevToolsFrontendClient.h" | 53 #include "WebDevToolsFrontendClient.h" |
| 56 #include "WebFrameImpl.h" | 54 #include "WebFrameImpl.h" |
| 57 #include "WebScriptSource.h" | 55 #include "WebScriptSource.h" |
| 58 #include "WebViewImpl.h" | 56 #include "WebViewImpl.h" |
| 57 #include "core/platform/ContextMenuItem.h" |
| 58 #include "core/platform/Pasteboard.h" |
| 59 #include <wtf/OwnPtr.h> | 59 #include <wtf/OwnPtr.h> |
| 60 #include <wtf/text/WTFString.h> |
| 60 #include <wtf/Vector.h> | 61 #include <wtf/Vector.h> |
| 61 #include <wtf/text/WTFString.h> | |
| 62 | 62 |
| 63 using namespace WebCore; | 63 using namespace WebCore; |
| 64 | 64 |
| 65 namespace WebKit { | 65 namespace WebKit { |
| 66 | 66 |
| 67 static v8::Local<v8::String> ToV8String(const String& s) | 67 static v8::Local<v8::String> ToV8String(const String& s) |
| 68 { | 68 { |
| 69 if (s.isNull()) | 69 if (s.isNull()) |
| 70 return v8::Local<v8::String>(); | 70 return v8::Local<v8::String>(); |
| 71 | 71 |
| (...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 119 return; | 119 return; |
| 120 v8::Handle<v8::Function> function = v8::Handle<v8::Function>::Cast(dispatchF
unction); | 120 v8::Handle<v8::Function> function = v8::Handle<v8::Function>::Cast(dispatchF
unction); |
| 121 Vector< v8::Handle<v8::Value> > args; | 121 Vector< v8::Handle<v8::Value> > args; |
| 122 args.append(ToV8String(message)); | 122 args.append(ToV8String(message)); |
| 123 v8::TryCatch tryCatch; | 123 v8::TryCatch tryCatch; |
| 124 tryCatch.SetVerbose(true); | 124 tryCatch.SetVerbose(true); |
| 125 ScriptController::callFunctionWithInstrumentation(frame->frame() ? frame->fr
ame()->document() : 0, function, inspectorFrontendApi, args.size(), args.data())
; | 125 ScriptController::callFunctionWithInstrumentation(frame->frame() ? frame->fr
ame()->document() : 0, function, inspectorFrontendApi, args.size(), args.data())
; |
| 126 } | 126 } |
| 127 | 127 |
| 128 } // namespace WebKit | 128 } // namespace WebKit |
| OLD | NEW |