| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2013 Google Inc. All rights reserved. | 2 * Copyright (C) 2013 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
| 6 * met: | 6 * met: |
| 7 * | 7 * |
| 8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 68 return static_cast<TestInterfaceNamedConstructor2*>(object); | 68 return static_cast<TestInterfaceNamedConstructor2*>(object); |
| 69 } | 69 } |
| 70 static void installPerContextEnabledProperties(v8::Handle<v8::Object>, TestI
nterfaceNamedConstructor2*, v8::Isolate*) { } | 70 static void installPerContextEnabledProperties(v8::Handle<v8::Object>, TestI
nterfaceNamedConstructor2*, v8::Isolate*) { } |
| 71 static void installPerContextEnabledMethods(v8::Handle<v8::Object>, v8::Isol
ate*) { } | 71 static void installPerContextEnabledMethods(v8::Handle<v8::Object>, v8::Isol
ate*) { } |
| 72 | 72 |
| 73 private: | 73 private: |
| 74 friend v8::Handle<v8::Object> wrap(TestInterfaceNamedConstructor2*, v8::Hand
le<v8::Object> creationContext, v8::Isolate*); | 74 friend v8::Handle<v8::Object> wrap(TestInterfaceNamedConstructor2*, v8::Hand
le<v8::Object> creationContext, v8::Isolate*); |
| 75 static v8::Handle<v8::Object> createWrapper(PassRefPtr<TestInterfaceNamedCon
structor2>, v8::Handle<v8::Object> creationContext, v8::Isolate*); | 75 static v8::Handle<v8::Object> createWrapper(PassRefPtr<TestInterfaceNamedCon
structor2>, v8::Handle<v8::Object> creationContext, v8::Isolate*); |
| 76 }; | 76 }; |
| 77 | 77 |
| 78 template<> | |
| 79 class WrapperTypeTraits<TestInterfaceNamedConstructor2 > { | |
| 80 public: | |
| 81 static const WrapperTypeInfo* wrapperTypeInfo() { return &V8TestInterfaceNam
edConstructor2::wrapperTypeInfo; } | |
| 82 }; | |
| 83 | |
| 84 inline v8::Handle<v8::Object> wrap(TestInterfaceNamedConstructor2* impl, v8::Han
dle<v8::Object> creationContext, v8::Isolate* isolate) | 78 inline v8::Handle<v8::Object> wrap(TestInterfaceNamedConstructor2* impl, v8::Han
dle<v8::Object> creationContext, v8::Isolate* isolate) |
| 85 { | 79 { |
| 86 ASSERT(impl); | 80 ASSERT(impl); |
| 87 ASSERT(!DOMDataStore::containsWrapper<V8TestInterfaceNamedConstructor2>(impl
, isolate)); | 81 ASSERT(!DOMDataStore::containsWrapper<V8TestInterfaceNamedConstructor2>(impl
, isolate)); |
| 88 return V8TestInterfaceNamedConstructor2::createWrapper(impl, creationContext
, isolate); | 82 return V8TestInterfaceNamedConstructor2::createWrapper(impl, creationContext
, isolate); |
| 89 } | 83 } |
| 90 | 84 |
| 91 inline v8::Handle<v8::Value> toV8(TestInterfaceNamedConstructor2* impl, v8::Hand
le<v8::Object> creationContext, v8::Isolate* isolate) | 85 inline v8::Handle<v8::Value> toV8(TestInterfaceNamedConstructor2* impl, v8::Hand
le<v8::Object> creationContext, v8::Isolate* isolate) |
| 92 { | 86 { |
| 93 if (UNLIKELY(!impl)) | 87 if (UNLIKELY(!impl)) |
| (...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 156 } | 150 } |
| 157 | 151 |
| 158 template<class CallbackInfo, class Wrappable> | 152 template<class CallbackInfo, class Wrappable> |
| 159 inline void v8SetReturnValueFast(const CallbackInfo& callbackInfo, PassRefPtr<Te
stInterfaceNamedConstructor2> impl, Wrappable* wrappable) | 153 inline void v8SetReturnValueFast(const CallbackInfo& callbackInfo, PassRefPtr<Te
stInterfaceNamedConstructor2> impl, Wrappable* wrappable) |
| 160 { | 154 { |
| 161 v8SetReturnValueFast(callbackInfo, impl.get(), wrappable); | 155 v8SetReturnValueFast(callbackInfo, impl.get(), wrappable); |
| 162 } | 156 } |
| 163 | 157 |
| 164 } | 158 } |
| 165 #endif // V8TestInterfaceNamedConstructor2_h | 159 #endif // V8TestInterfaceNamedConstructor2_h |
| OLD | NEW |