Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 // This file has been auto-generated by code_generator_v8.py. DO NOT MODIFY! | 5 // This file has been auto-generated by code_generator_v8.py. DO NOT MODIFY! |
| 6 | 6 |
| 7 #include "config.h" | 7 #include "config.h" |
| 8 #include "V8TestObject.h" | 8 #include "V8TestObject.h" |
| 9 | 9 |
| 10 #include "bindings/core/v8/BindingSecurity.h" | 10 #include "bindings/core/v8/BindingSecurity.h" |
| (...skipping 6197 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 6208 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); | 6208 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); |
| 6209 } | 6209 } |
| 6210 | 6210 |
| 6211 static void voidMethodNullableVoidCallbackFunctionArgMethod(const v8::FunctionCa llbackInfo<v8::Value>& info) | 6211 static void voidMethodNullableVoidCallbackFunctionArgMethod(const v8::FunctionCa llbackInfo<v8::Value>& info) |
| 6212 { | 6212 { |
| 6213 if (UNLIKELY(info.Length() < 1)) { | 6213 if (UNLIKELY(info.Length() < 1)) { |
| 6214 V8ThrowException::throwException(createMinimumArityTypeErrorForMethod(in fo.GetIsolate(), "voidMethodNullableVoidCallbackFunctionArg", "TestObject", 1, i nfo.Length()), info.GetIsolate()); | 6214 V8ThrowException::throwException(createMinimumArityTypeErrorForMethod(in fo.GetIsolate(), "voidMethodNullableVoidCallbackFunctionArg", "TestObject", 1, i nfo.Length()), info.GetIsolate()); |
| 6215 return; | 6215 return; |
| 6216 } | 6216 } |
| 6217 TestObject* impl = V8TestObject::toImpl(info.Holder()); | 6217 TestObject* impl = V8TestObject::toImpl(info.Holder()); |
| 6218 ScriptValue voidCallbackFunctionArg; | 6218 Nullable<ScriptValue> voidCallbackFunctionArg; |
|
Jens Widell
2015/03/02 07:53:13
This is wrong; ScriptValue can store null, so shou
| |
| 6219 { | 6219 { |
| 6220 if (!info[0]->IsFunction() && !info[0]->IsNull()) { | 6220 if (!info[0]->IsFunction() && !info[0]->IsNull()) { |
| 6221 V8ThrowException::throwTypeError(info.GetIsolate(), ExceptionMessage s::failedToExecute("voidMethodNullableVoidCallbackFunctionArg", "TestObject", "T he callback provided as parameter 1 is not a function.")); | 6221 V8ThrowException::throwTypeError(info.GetIsolate(), ExceptionMessage s::failedToExecute("voidMethodNullableVoidCallbackFunctionArg", "TestObject", "T he callback provided as parameter 1 is not a function.")); |
| 6222 return; | 6222 return; |
| 6223 } | 6223 } |
| 6224 voidCallbackFunctionArg = ScriptValue(ScriptState::current(info.GetIsola te()), info[0]); | 6224 voidCallbackFunctionArg = ScriptValue(ScriptState::current(info.GetIsola te()), info[0]); |
| 6225 } | 6225 } |
| 6226 impl->voidMethodNullableVoidCallbackFunctionArg(voidCallbackFunctionArg); | 6226 impl->voidMethodNullableVoidCallbackFunctionArg(voidCallbackFunctionArg); |
| 6227 } | 6227 } |
| 6228 | 6228 |
| (...skipping 6453 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 12682 return false; | 12682 return false; |
| 12683 | 12683 |
| 12684 ScriptState::Scope scope(scriptState); | 12684 ScriptState::Scope scope(scriptState); |
| 12685 v8::Local<v8::Value> holder = toV8(holderImpl, scriptState->context()->Globa l(), scriptState->isolate()); | 12685 v8::Local<v8::Value> holder = toV8(holderImpl, scriptState->context()->Globa l(), scriptState->isolate()); |
| 12686 | 12686 |
| 12687 ExceptionState exceptionState(ExceptionState::SetterContext, "enumForPrivate Script", "TestObject", scriptState->context()->Global(), scriptState->isolate()) ; | 12687 ExceptionState exceptionState(ExceptionState::SetterContext, "enumForPrivate Script", "TestObject", scriptState->context()->Global(), scriptState->isolate()) ; |
| 12688 return PrivateScriptRunner::runDOMAttributeSetter(scriptState, scriptStateIn UserScript, "TestObject", "enumForPrivateScript", holder, v8String(scriptState-> isolate(), cppValue)); | 12688 return PrivateScriptRunner::runDOMAttributeSetter(scriptState, scriptStateIn UserScript, "TestObject", "enumForPrivateScript", holder, v8String(scriptState-> isolate(), cppValue)); |
| 12689 } | 12689 } |
| 12690 | 12690 |
| 12691 } // namespace blink | 12691 } // namespace blink |
| OLD | NEW |