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 #ifndef V8TestInterfaceWillBeGarbageCollected_h | 7 #ifndef V8TestInterfaceWillBeGarbageCollected_h |
8 #define V8TestInterfaceWillBeGarbageCollected_h | 8 #define V8TestInterfaceWillBeGarbageCollected_h |
9 | 9 |
10 #include "bindings/core/v8/ScriptWrappable.h" | 10 #include "bindings/core/v8/ScriptWrappable.h" |
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
65 | 65 |
66 v8::Handle<v8::Object> wrap(TestInterfaceWillBeGarbageCollected* impl, v8::Handl
e<v8::Object> creationContext, v8::Isolate*); | 66 v8::Handle<v8::Object> wrap(TestInterfaceWillBeGarbageCollected* impl, v8::Handl
e<v8::Object> creationContext, v8::Isolate*); |
67 | 67 |
68 inline v8::Handle<v8::Value> toV8(TestInterfaceWillBeGarbageCollected* impl, v8:
:Handle<v8::Object> creationContext, v8::Isolate* isolate) | 68 inline v8::Handle<v8::Value> toV8(TestInterfaceWillBeGarbageCollected* impl, v8:
:Handle<v8::Object> creationContext, v8::Isolate* isolate) |
69 { | 69 { |
70 if (UNLIKELY(!impl)) | 70 if (UNLIKELY(!impl)) |
71 return v8::Null(isolate); | 71 return v8::Null(isolate); |
72 v8::Handle<v8::Value> wrapper = DOMDataStore::getWrapper<V8TestInterfaceWill
BeGarbageCollected>(impl, isolate); | 72 v8::Handle<v8::Value> wrapper = DOMDataStore::getWrapper<V8TestInterfaceWill
BeGarbageCollected>(impl, isolate); |
73 if (!wrapper.IsEmpty()) | 73 if (!wrapper.IsEmpty()) |
74 return wrapper; | 74 return wrapper; |
75 return wrap(impl, creationContext, isolate); | 75 |
| 76 return impl->wrap(creationContext, isolate); |
76 } | 77 } |
77 | 78 |
78 template<typename CallbackInfo> | 79 template<typename CallbackInfo> |
79 inline void v8SetReturnValue(const CallbackInfo& callbackInfo, TestInterfaceWill
BeGarbageCollected* impl) | 80 inline void v8SetReturnValue(const CallbackInfo& callbackInfo, TestInterfaceWill
BeGarbageCollected* impl) |
80 { | 81 { |
81 if (UNLIKELY(!impl)) { | 82 if (UNLIKELY(!impl)) { |
82 v8SetReturnValueNull(callbackInfo); | 83 v8SetReturnValueNull(callbackInfo); |
83 return; | 84 return; |
84 } | 85 } |
85 if (DOMDataStore::setReturnValueFromWrapper<V8TestInterfaceWillBeGarbageColl
ected>(callbackInfo.GetReturnValue(), impl)) | 86 if (DOMDataStore::setReturnValueFromWrapper<V8TestInterfaceWillBeGarbageColl
ected>(callbackInfo.GetReturnValue(), impl)) |
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
133 } | 134 } |
134 | 135 |
135 template<class CallbackInfo, class Wrappable> | 136 template<class CallbackInfo, class Wrappable> |
136 inline void v8SetReturnValueFast(const CallbackInfo& callbackInfo, PassRefPtrWil
lBeRawPtr<TestInterfaceWillBeGarbageCollected> impl, Wrappable* wrappable) | 137 inline void v8SetReturnValueFast(const CallbackInfo& callbackInfo, PassRefPtrWil
lBeRawPtr<TestInterfaceWillBeGarbageCollected> impl, Wrappable* wrappable) |
137 { | 138 { |
138 v8SetReturnValueFast(callbackInfo, impl.get(), wrappable); | 139 v8SetReturnValueFast(callbackInfo, impl.get(), wrappable); |
139 } | 140 } |
140 | 141 |
141 } // namespace blink | 142 } // namespace blink |
142 #endif // V8TestInterfaceWillBeGarbageCollected_h | 143 #endif // V8TestInterfaceWillBeGarbageCollected_h |
OLD | NEW |