diff options
author | Ben Murdoch <benm@google.com> | 2011-05-13 16:23:25 +0100 |
---|---|---|
committer | Ben Murdoch <benm@google.com> | 2011-05-16 11:35:02 +0100 |
commit | 65f03d4f644ce73618e5f4f50dd694b26f55ae12 (patch) | |
tree | f478babb801e720de7bfaee23443ffe029f58731 /Source/WebCore/bindings/v8 | |
parent | 47de4a2fb7262c7ebdb9cd133ad2c54c187454d0 (diff) | |
download | external_webkit-65f03d4f644ce73618e5f4f50dd694b26f55ae12.zip external_webkit-65f03d4f644ce73618e5f4f50dd694b26f55ae12.tar.gz external_webkit-65f03d4f644ce73618e5f4f50dd694b26f55ae12.tar.bz2 |
Merge WebKit at r75993: Initial merge by git.
Change-Id: I602bbdc3974787a3b0450456a30a7868286921c3
Diffstat (limited to 'Source/WebCore/bindings/v8')
4 files changed, 22 insertions, 4 deletions
diff --git a/Source/WebCore/bindings/v8/DebuggerScript.js b/Source/WebCore/bindings/v8/DebuggerScript.js index 50f791d..8c9d98e 100644 --- a/Source/WebCore/bindings/v8/DebuggerScript.js +++ b/Source/WebCore/bindings/v8/DebuggerScript.js @@ -83,8 +83,8 @@ DebuggerScript._formatScript = function(script) id: script.id, name: script.nameOrSourceURL(), source: script.source, - lineOffset: DebuggerScript._v8ToWebkitLineNumber(script.line_offset), - lineCount: script.lineCount(), + lineOffset: script.line_offset, + columnOffset: script.column_offset, scriptWorldType: scriptWorldType }; } diff --git a/Source/WebCore/bindings/v8/ScriptDebugServer.cpp b/Source/WebCore/bindings/v8/ScriptDebugServer.cpp index 4b4611a..1c70a0e 100644 --- a/Source/WebCore/bindings/v8/ScriptDebugServer.cpp +++ b/Source/WebCore/bindings/v8/ScriptDebugServer.cpp @@ -447,6 +447,7 @@ void ScriptDebugServer::dispatchDidParseSource(ScriptDebugListener* listener, v8 toWebCoreStringWithNullOrUndefinedCheck(object->Get(v8::String::New("name"))), toWebCoreStringWithNullOrUndefinedCheck(object->Get(v8::String::New("source"))), object->Get(v8::String::New("lineOffset"))->ToInteger()->Value(), + object->Get(v8::String::New("columnOffset"))->ToInteger()->Value(), static_cast<ScriptWorldType>(object->Get(v8::String::New("scriptWorldType"))->Int32Value())); } diff --git a/Source/WebCore/bindings/v8/custom/V8DocumentCustom.cpp b/Source/WebCore/bindings/v8/custom/V8DocumentCustom.cpp index 9fa9f80..cda0737 100644 --- a/Source/WebCore/bindings/v8/custom/V8DocumentCustom.cpp +++ b/Source/WebCore/bindings/v8/custom/V8DocumentCustom.cpp @@ -35,6 +35,7 @@ #include "Document.h" #include "ExceptionCode.h" #include "Node.h" +#include "TouchList.h" #include "XPathNSResolver.h" #include "XPathResult.h" @@ -46,6 +47,8 @@ #include "V8IsolatedContext.h" #include "V8Node.h" #include "V8Proxy.h" +#include "V8Touch.h" +#include "V8TouchList.h" #if ENABLE(3D_CANVAS) #include "V8WebGLRenderingContext.h" #endif @@ -163,4 +166,19 @@ v8::Handle<v8::Value> toV8(Document* impl, bool forceNewObject) return wrapper; } +#if ENABLE(TOUCH_EVENTS) +v8::Handle<v8::Value> V8Document::createTouchListCallback(const v8::Arguments& args) +{ + RefPtr<TouchList> touchList = TouchList::create(); + + for (int i = 0; i < args.Length(); i++) { + if (!args[i]->IsObject()) + return v8::Undefined(); + touchList->append(V8Touch::toNative(args[i]->ToObject())); + } + + return toV8(touchList.release()); +} +#endif + } // namespace WebCore diff --git a/Source/WebCore/bindings/v8/custom/V8InjectedScriptHostCustom.cpp b/Source/WebCore/bindings/v8/custom/V8InjectedScriptHostCustom.cpp index 81ad955..6bd5abb 100644 --- a/Source/WebCore/bindings/v8/custom/V8InjectedScriptHostCustom.cpp +++ b/Source/WebCore/bindings/v8/custom/V8InjectedScriptHostCustom.cpp @@ -241,8 +241,7 @@ InjectedScript InjectedScriptHost::injectedScriptFor(ScriptState* inspectedScrip if (!canAccessInspectedWindow(inspectedScriptState)) return InjectedScript(); - ASSERT(!m_injectedScriptSource.isEmpty()); - pair<long, ScriptObject> injectedScript = injectScript(m_injectedScriptSource, inspectedScriptState); + pair<long, ScriptObject> injectedScript = injectScript(injectedScriptSource(), inspectedScriptState); InjectedScript result(injectedScript.second); m_idToInjectedScript.set(injectedScript.first, result); global->SetHiddenValue(key, injectedScript.second.v8Object()); |