| 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 V8TestInterfaceGarbageCollected_h | 7 #ifndef V8TestInterfaceGarbageCollected_h |
| 8 #define V8TestInterfaceGarbageCollected_h | 8 #define V8TestInterfaceGarbageCollected_h |
| 9 | 9 |
| 10 #include "bindings/core/v8/ScriptWrappable.h" | 10 #include "bindings/core/v8/ScriptWrappable.h" |
| (...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 55 | 55 |
| 56 v8::Handle<v8::Object> wrap(TestInterfaceGarbageCollected* impl, v8::Handle<v8::
Object> creationContext, v8::Isolate*); | 56 v8::Handle<v8::Object> wrap(TestInterfaceGarbageCollected* impl, v8::Handle<v8::
Object> creationContext, v8::Isolate*); |
| 57 | 57 |
| 58 inline v8::Handle<v8::Value> toV8(TestInterfaceGarbageCollected* impl, v8::Handl
e<v8::Object> creationContext, v8::Isolate* isolate) | 58 inline v8::Handle<v8::Value> toV8(TestInterfaceGarbageCollected* impl, v8::Handl
e<v8::Object> creationContext, v8::Isolate* isolate) |
| 59 { | 59 { |
| 60 if (UNLIKELY(!impl)) | 60 if (UNLIKELY(!impl)) |
| 61 return v8::Null(isolate); | 61 return v8::Null(isolate); |
| 62 v8::Handle<v8::Value> wrapper = DOMDataStore::getWrapper<V8TestInterfaceGarb
ageCollected>(impl, isolate); | 62 v8::Handle<v8::Value> wrapper = DOMDataStore::getWrapper<V8TestInterfaceGarb
ageCollected>(impl, isolate); |
| 63 if (!wrapper.IsEmpty()) | 63 if (!wrapper.IsEmpty()) |
| 64 return wrapper; | 64 return wrapper; |
| 65 return wrap(impl, creationContext, isolate); | 65 |
| 66 return impl->wrap(creationContext, isolate); |
| 66 } | 67 } |
| 67 | 68 |
| 68 template<typename CallbackInfo> | 69 template<typename CallbackInfo> |
| 69 inline void v8SetReturnValue(const CallbackInfo& callbackInfo, TestInterfaceGarb
ageCollected* impl) | 70 inline void v8SetReturnValue(const CallbackInfo& callbackInfo, TestInterfaceGarb
ageCollected* impl) |
| 70 { | 71 { |
| 71 if (UNLIKELY(!impl)) { | 72 if (UNLIKELY(!impl)) { |
| 72 v8SetReturnValueNull(callbackInfo); | 73 v8SetReturnValueNull(callbackInfo); |
| 73 return; | 74 return; |
| 74 } | 75 } |
| 75 if (DOMDataStore::setReturnValueFromWrapper<V8TestInterfaceGarbageCollected>
(callbackInfo.GetReturnValue(), impl)) | 76 if (DOMDataStore::setReturnValueFromWrapper<V8TestInterfaceGarbageCollected>
(callbackInfo.GetReturnValue(), impl)) |
| (...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 123 } | 124 } |
| 124 | 125 |
| 125 template<class CallbackInfo, class Wrappable> | 126 template<class CallbackInfo, class Wrappable> |
| 126 inline void v8SetReturnValueFast(const CallbackInfo& callbackInfo, RawPtr<TestIn
terfaceGarbageCollected> impl, Wrappable* wrappable) | 127 inline void v8SetReturnValueFast(const CallbackInfo& callbackInfo, RawPtr<TestIn
terfaceGarbageCollected> impl, Wrappable* wrappable) |
| 127 { | 128 { |
| 128 v8SetReturnValueFast(callbackInfo, impl.get(), wrappable); | 129 v8SetReturnValueFast(callbackInfo, impl.get(), wrappable); |
| 129 } | 130 } |
| 130 | 131 |
| 131 } // namespace blink | 132 } // namespace blink |
| 132 #endif // V8TestInterfaceGarbageCollected_h | 133 #endif // V8TestInterfaceGarbageCollected_h |
| OLD | NEW |