static v8::Handle<v8::Value> closeCallback(const v8::Arguments& args) { INC_STATS("DOM.MessagePort.close"); MessagePort* imp = V8MessagePort::toNative(args.Holder()); imp->close(); return v8::Handle<v8::Value>(); }
JSValue JSC_HOST_CALL jsMessagePortPrototypeFunctionClose(ExecState* exec, JSObject*, JSValue thisValue, const ArgList& args) { UNUSED_PARAM(args); if (!thisValue.inherits(&JSMessagePort::s_info)) return throwError(exec, TypeError); JSMessagePort* castedThisObj = static_cast<JSMessagePort*>(asObject(thisValue)); MessagePort* imp = static_cast<MessagePort*>(castedThisObj->impl()); imp->close(); return jsUndefined(); }
EncodedJSValue JSC_HOST_CALL jsMessagePortPrototypeFunctionClose(ExecState* exec) { JSValue thisValue = exec->hostThisValue(); if (!thisValue.inherits(&JSMessagePort::s_info)) return throwVMTypeError(exec); JSMessagePort* castedThis = static_cast<JSMessagePort*>(asObject(thisValue)); ASSERT_GC_OBJECT_INHERITS(castedThis, &JSMessagePort::s_info); MessagePort* imp = static_cast<MessagePort*>(castedThis->impl()); imp->close(); return JSValue::encode(jsUndefined()); }
static v8::Handle<v8::Value> closeCallback(const v8::Arguments& args) { MessagePort* imp = V8MessagePort::toNative(args.Holder()); imp->close(); return v8Undefined(); }