Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(308)

Unified Diff: Source/bindings/core/v8/custom/V8NodeCustom.cpp

Issue 375293002: Node.insertBefore and Node.appendChild do not use custom binding anymore (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Take review comment into consideration Created 6 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: Source/bindings/core/v8/custom/V8NodeCustom.cpp
diff --git a/Source/bindings/core/v8/custom/V8NodeCustom.cpp b/Source/bindings/core/v8/custom/V8NodeCustom.cpp
index 80ad75a95086a945f167ca65eb3e56db4ba1d230..c7a17c8d1ab68b9c4a3154f668282f80e16a5c67 100644
--- a/Source/bindings/core/v8/custom/V8NodeCustom.cpp
+++ b/Source/bindings/core/v8/custom/V8NodeCustom.cpp
@@ -58,22 +58,6 @@ namespace WebCore {
// These functions are custom to prevent a wrapper lookup of the return value which is always
// part of the arguments.
-void V8Node::insertBeforeMethodCustom(const v8::FunctionCallbackInfo<v8::Value>& info)
-{
- v8::Handle<v8::Object> holder = info.Holder();
- Node* impl = V8Node::toNative(holder);
-
- CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope;
-
- ExceptionState exceptionState(ExceptionState::ExecutionContext, "insertBefore", "Node", info.Holder(), info.GetIsolate());
- Node* newChild = V8Node::toNativeWithTypeCheck(info.GetIsolate(), info[0]);
- Node* refChild = V8Node::toNativeWithTypeCheck(info.GetIsolate(), info[1]);
- impl->insertBefore(newChild, refChild, exceptionState);
- if (exceptionState.throwIfNeeded())
- return;
- v8SetReturnValue(info, info[0]);
-}
-
void V8Node::replaceChildMethodCustom(const v8::FunctionCallbackInfo<v8::Value>& info)
{
v8::Handle<v8::Object> holder = info.Holder();
@@ -105,34 +89,6 @@ void V8Node::removeChildMethodCustom(const v8::FunctionCallbackInfo<v8::Value>&
v8SetReturnValue(info, info[0]);
}
-void V8Node::appendChildMethodCustom(const v8::FunctionCallbackInfo<v8::Value>& info)
-{
- ExceptionState exceptionState(ExceptionState::ExecutionContext, "appendChild", "Node", info.Holder(), info.GetIsolate());
- if (UNLIKELY(info.Length() < 1)) {
- throwMinimumArityTypeErrorForMethod("appendChild", "Node", 1, info.Length(), info.GetIsolate());
- return;
- }
- Node* impl = V8Node::toNative(info.Holder());
- CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope;
- Node* newChild;
- {
- v8::TryCatch block;
- V8RethrowTryCatchScope rethrow(block);
- if (info.Length() > 0 && !V8Node::hasInstance(info[0], info.GetIsolate())) {
- exceptionState.throwTypeError("parameter 1 is not of type 'Node'.");
- exceptionState.throwIfNeeded();
- return;
- }
- TONATIVE_VOID_INTERNAL(newChild, V8Node::toNativeWithTypeCheck(info.GetIsolate(), info[0]));
- }
- impl->appendChild(newChild, exceptionState);
- if (exceptionState.hadException()) {
- exceptionState.throwIfNeeded();
- return;
- }
- v8SetReturnValue(info, info[0]);
-}
-
v8::Handle<v8::Object> wrap(Node* impl, v8::Handle<v8::Object> creationContext, v8::Isolate* isolate)
{
ASSERT(impl);

Powered by Google App Engine
This is Rietveld 408576698