| OLD | NEW |
| 1 /* | 1 /* |
| 2 This file is part of the Blink open source project. | 2 This file is part of the Blink open source project. |
| 3 This file has been auto-generated by CodeGeneratorV8.pm. DO NOT MODIFY! | 3 This file has been auto-generated by CodeGeneratorV8.pm. DO NOT MODIFY! |
| 4 | 4 |
| 5 This library is free software; you can redistribute it and/or | 5 This library is free software; you can redistribute it and/or |
| 6 modify it under the terms of the GNU Library General Public | 6 modify it under the terms of the GNU Library General Public |
| 7 License as published by the Free Software Foundation; either | 7 License as published by the Free Software Foundation; either |
| 8 version 2 of the License, or (at your option) any later version. | 8 version 2 of the License, or (at your option) any later version. |
| 9 | 9 |
| 10 This library is distributed in the hope that it will be useful, | 10 This library is distributed in the hope that it will be useful, |
| 11 but WITHOUT ANY WARRANTY; without even the implied warranty of | 11 but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | 12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
| 13 Library General Public License for more details. | 13 Library General Public License for more details. |
| 14 | 14 |
| 15 You should have received a copy of the GNU Library General Public License | 15 You should have received a copy of the GNU Library General Public License |
| 16 along with this library; see the file COPYING.LIB. If not, write to | 16 along with this library; see the file COPYING.LIB. If not, write to |
| 17 the Free Software Foundation, Inc., 59 Temple Place - Suite 330, | 17 the Free Software Foundation, Inc., 59 Temple Place - Suite 330, |
| 18 Boston, MA 02111-1307, USA. | 18 Boston, MA 02111-1307, USA. |
| 19 */ | 19 */ |
| 20 | 20 |
| 21 #include "config.h" | 21 #include "config.h" |
| 22 #include "V8TestNode.h" | 22 #include "V8TestNode.h" |
| 23 | 23 |
| 24 #include "RuntimeEnabledFeatures.h" | 24 #include "RuntimeEnabledFeatures.h" |
| 25 #include "V8Node.h" | 25 #include "V8Node.h" |
| 26 #include "bindings/v8/ExceptionMessages.h" |
| 26 #include "bindings/v8/ScriptController.h" | 27 #include "bindings/v8/ScriptController.h" |
| 27 #include "bindings/v8/V8Binding.h" | 28 #include "bindings/v8/V8Binding.h" |
| 28 #include "bindings/v8/V8DOMConfiguration.h" | 29 #include "bindings/v8/V8DOMConfiguration.h" |
| 29 #include "bindings/v8/V8DOMWrapper.h" | 30 #include "bindings/v8/V8DOMWrapper.h" |
| 30 #include "bindings/v8/V8ObjectConstructor.h" | 31 #include "bindings/v8/V8ObjectConstructor.h" |
| 31 #include "core/dom/ContextFeatures.h" | 32 #include "core/dom/ContextFeatures.h" |
| 32 #include "core/dom/Document.h" | 33 #include "core/dom/Document.h" |
| 33 #include "core/platform/chromium/TraceEvent.h" | 34 #include "core/platform/chromium/TraceEvent.h" |
| 34 #include "wtf/UnusedParam.h" | 35 #include "wtf/UnusedParam.h" |
| 35 | 36 |
| (...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 70 V8DOMWrapper::associateObjectWithWrapper<V8TestNode>(impl.release(), &V8Test
Node::info, wrapper, args.GetIsolate(), WrapperConfiguration::Dependent); | 71 V8DOMWrapper::associateObjectWithWrapper<V8TestNode>(impl.release(), &V8Test
Node::info, wrapper, args.GetIsolate(), WrapperConfiguration::Dependent); |
| 71 args.GetReturnValue().Set(wrapper); | 72 args.GetReturnValue().Set(wrapper); |
| 72 } | 73 } |
| 73 | 74 |
| 74 } // namespace TestNodeV8Internal | 75 } // namespace TestNodeV8Internal |
| 75 | 76 |
| 76 void V8TestNode::constructorCallback(const v8::FunctionCallbackInfo<v8::Value>&
args) | 77 void V8TestNode::constructorCallback(const v8::FunctionCallbackInfo<v8::Value>&
args) |
| 77 { | 78 { |
| 78 TRACE_EVENT_SCOPED_SAMPLING_STATE("Blink", "DOMConstructor"); | 79 TRACE_EVENT_SCOPED_SAMPLING_STATE("Blink", "DOMConstructor"); |
| 79 if (!args.IsConstructCall()) { | 80 if (!args.IsConstructCall()) { |
| 80 throwTypeError("DOM object constructor cannot be called as a function.",
args.GetIsolate()); | 81 throwTypeError(ExceptionMessages::failedToConstruct("TestNode", "Please
use the 'new' operator, this DOM object constructor cannot be called as a functi
on."), args.GetIsolate()); |
| 81 return; | 82 return; |
| 82 } | 83 } |
| 83 | 84 |
| 84 if (ConstructorMode::current() == ConstructorMode::WrapExistingObject) { | 85 if (ConstructorMode::current() == ConstructorMode::WrapExistingObject) { |
| 85 args.GetReturnValue().Set(args.Holder()); | 86 args.GetReturnValue().Set(args.Holder()); |
| 86 return; | 87 return; |
| 87 } | 88 } |
| 88 | 89 |
| 89 TestNodeV8Internal::constructor(args); | 90 TestNodeV8Internal::constructor(args); |
| 90 } | 91 } |
| (...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 157 V8DOMWrapper::associateObjectWithWrapper<V8TestNode>(impl, &info, wrapper, i
solate, WrapperConfiguration::Dependent); | 158 V8DOMWrapper::associateObjectWithWrapper<V8TestNode>(impl, &info, wrapper, i
solate, WrapperConfiguration::Dependent); |
| 158 return wrapper; | 159 return wrapper; |
| 159 } | 160 } |
| 160 | 161 |
| 161 void V8TestNode::derefObject(void* object) | 162 void V8TestNode::derefObject(void* object) |
| 162 { | 163 { |
| 163 fromInternalPointer(object)->deref(); | 164 fromInternalPointer(object)->deref(); |
| 164 } | 165 } |
| 165 | 166 |
| 166 } // namespace WebCore | 167 } // namespace WebCore |
| OLD | NEW |