| Index: Source/bindings/tests/results/V8TestConstants.h
|
| diff --git a/Source/bindings/tests/results/V8TestException.h b/Source/bindings/tests/results/V8TestConstants.h
|
| similarity index 71%
|
| copy from Source/bindings/tests/results/V8TestException.h
|
| copy to Source/bindings/tests/results/V8TestConstants.h
|
| index de2c394733cc03dd339e1fc294276da752e028d8..65d9e94178b2a3af742ec8e3ad3b39d303c305d2 100644
|
| --- a/Source/bindings/tests/results/V8TestException.h
|
| +++ b/Source/bindings/tests/results/V8TestConstants.h
|
| @@ -18,131 +18,131 @@
|
| Boston, MA 02111-1307, USA.
|
| */
|
|
|
| -#ifndef V8TestException_h
|
| -#define V8TestException_h
|
| +#ifndef V8TestConstants_h
|
| +#define V8TestConstants_h
|
|
|
| -#include "bindings/tests/idls/TestException.h"
|
| +#include "bindings/tests/idls/TestConstants.h"
|
| #include "bindings/v8/V8Binding.h"
|
| #include "bindings/v8/V8DOMWrapper.h"
|
| #include "bindings/v8/WrapperTypeInfo.h"
|
|
|
| namespace WebCore {
|
|
|
| -class V8TestException {
|
| +class V8TestConstants {
|
| public:
|
| static bool HasInstance(v8::Handle<v8::Value>, v8::Isolate*, WrapperWorldType);
|
| static bool HasInstanceInAnyWorld(v8::Handle<v8::Value>, v8::Isolate*);
|
| static v8::Handle<v8::FunctionTemplate> GetTemplate(v8::Isolate*, WrapperWorldType);
|
| - static TestException* toNative(v8::Handle<v8::Object> object)
|
| + static TestConstants* toNative(v8::Handle<v8::Object> object)
|
| {
|
| return fromInternalPointer(object->GetAlignedPointerFromInternalField(v8DOMWrapperObjectIndex));
|
| }
|
| static void derefObject(void*);
|
| static WrapperTypeInfo info;
|
| static const int internalFieldCount = v8DefaultWrapperInternalFieldCount + 0;
|
| - static inline void* toInternalPointer(TestException* impl)
|
| + static inline void* toInternalPointer(TestConstants* impl)
|
| {
|
| return impl;
|
| }
|
|
|
| - static inline TestException* fromInternalPointer(void* object)
|
| + static inline TestConstants* fromInternalPointer(void* object)
|
| {
|
| - return static_cast<TestException*>(object);
|
| + return static_cast<TestConstants*>(object);
|
| }
|
| - static void installPerContextProperties(v8::Handle<v8::Object>, TestException*, v8::Isolate*) { }
|
| + static void installPerContextProperties(v8::Handle<v8::Object>, TestConstants*, v8::Isolate*) { }
|
| static void installPerContextPrototypeProperties(v8::Handle<v8::Object>, v8::Isolate*) { }
|
|
|
| private:
|
| - friend v8::Handle<v8::Object> wrap(TestException*, v8::Handle<v8::Object> creationContext, v8::Isolate*);
|
| - static v8::Handle<v8::Object> createWrapper(PassRefPtr<TestException>, v8::Handle<v8::Object> creationContext, v8::Isolate*);
|
| + friend v8::Handle<v8::Object> wrap(TestConstants*, v8::Handle<v8::Object> creationContext, v8::Isolate*);
|
| + static v8::Handle<v8::Object> createWrapper(PassRefPtr<TestConstants>, v8::Handle<v8::Object> creationContext, v8::Isolate*);
|
| };
|
|
|
| template<>
|
| -class WrapperTypeTraits<TestException > {
|
| +class WrapperTypeTraits<TestConstants > {
|
| public:
|
| - static WrapperTypeInfo* info() { return &V8TestException::info; }
|
| + static WrapperTypeInfo* info() { return &V8TestConstants::info; }
|
| };
|
|
|
| -inline v8::Handle<v8::Object> wrap(TestException* impl, v8::Handle<v8::Object> creationContext, v8::Isolate* isolate)
|
| +inline v8::Handle<v8::Object> wrap(TestConstants* impl, v8::Handle<v8::Object> creationContext, v8::Isolate* isolate)
|
| {
|
| ASSERT(impl);
|
| - ASSERT(!DOMDataStore::containsWrapper<V8TestException>(impl, isolate));
|
| - return V8TestException::createWrapper(impl, creationContext, isolate);
|
| + ASSERT(!DOMDataStore::containsWrapper<V8TestConstants>(impl, isolate));
|
| + return V8TestConstants::createWrapper(impl, creationContext, isolate);
|
| }
|
|
|
| -inline v8::Handle<v8::Value> toV8(TestException* impl, v8::Handle<v8::Object> creationContext, v8::Isolate* isolate)
|
| +inline v8::Handle<v8::Value> toV8(TestConstants* impl, v8::Handle<v8::Object> creationContext, v8::Isolate* isolate)
|
| {
|
| if (UNLIKELY(!impl))
|
| return v8NullWithCheck(isolate);
|
| - v8::Handle<v8::Value> wrapper = DOMDataStore::getWrapper<V8TestException>(impl, isolate);
|
| + v8::Handle<v8::Value> wrapper = DOMDataStore::getWrapper<V8TestConstants>(impl, isolate);
|
| if (!wrapper.IsEmpty())
|
| return wrapper;
|
| return wrap(impl, creationContext, isolate);
|
| }
|
|
|
| template<typename CallbackInfo>
|
| -inline void v8SetReturnValue(const CallbackInfo& callbackInfo, TestException* impl, v8::Handle<v8::Object> creationContext)
|
| +inline void v8SetReturnValue(const CallbackInfo& callbackInfo, TestConstants* impl, v8::Handle<v8::Object> creationContext)
|
| {
|
| if (UNLIKELY(!impl)) {
|
| v8SetReturnValueNull(callbackInfo);
|
| return;
|
| }
|
| - if (DOMDataStore::setReturnValueFromWrapper<V8TestException>(callbackInfo.GetReturnValue(), impl))
|
| + if (DOMDataStore::setReturnValueFromWrapper<V8TestConstants>(callbackInfo.GetReturnValue(), impl))
|
| return;
|
| v8::Handle<v8::Object> wrapper = wrap(impl, creationContext, callbackInfo.GetIsolate());
|
| v8SetReturnValue(callbackInfo, wrapper);
|
| }
|
|
|
| template<typename CallbackInfo>
|
| -inline void v8SetReturnValueForMainWorld(const CallbackInfo& callbackInfo, TestException* impl, v8::Handle<v8::Object> creationContext)
|
| +inline void v8SetReturnValueForMainWorld(const CallbackInfo& callbackInfo, TestConstants* impl, v8::Handle<v8::Object> creationContext)
|
| {
|
| ASSERT(worldType(callbackInfo.GetIsolate()) == MainWorld);
|
| if (UNLIKELY(!impl)) {
|
| v8SetReturnValueNull(callbackInfo);
|
| return;
|
| }
|
| - if (DOMDataStore::setReturnValueFromWrapperForMainWorld<V8TestException>(callbackInfo.GetReturnValue(), impl))
|
| + if (DOMDataStore::setReturnValueFromWrapperForMainWorld<V8TestConstants>(callbackInfo.GetReturnValue(), impl))
|
| return;
|
| v8::Handle<v8::Value> wrapper = wrap(impl, creationContext, callbackInfo.GetIsolate());
|
| v8SetReturnValue(callbackInfo, wrapper);
|
| }
|
|
|
| template<class CallbackInfo, class Wrappable>
|
| -inline void v8SetReturnValueFast(const CallbackInfo& callbackInfo, TestException* impl, Wrappable* wrappable)
|
| +inline void v8SetReturnValueFast(const CallbackInfo& callbackInfo, TestConstants* impl, Wrappable* wrappable)
|
| {
|
| if (UNLIKELY(!impl)) {
|
| v8SetReturnValueNull(callbackInfo);
|
| return;
|
| }
|
| - if (DOMDataStore::setReturnValueFromWrapperFast<V8TestException>(callbackInfo.GetReturnValue(), impl, callbackInfo.Holder(), wrappable))
|
| + if (DOMDataStore::setReturnValueFromWrapperFast<V8TestConstants>(callbackInfo.GetReturnValue(), impl, callbackInfo.Holder(), wrappable))
|
| return;
|
| v8::Handle<v8::Object> wrapper = wrap(impl, callbackInfo.Holder(), callbackInfo.GetIsolate());
|
| v8SetReturnValue(callbackInfo, wrapper);
|
| }
|
|
|
| -inline v8::Handle<v8::Value> toV8(PassRefPtr<TestException > impl, v8::Handle<v8::Object> creationContext, v8::Isolate* isolate)
|
| +inline v8::Handle<v8::Value> toV8(PassRefPtr<TestConstants > impl, v8::Handle<v8::Object> creationContext, v8::Isolate* isolate)
|
| {
|
| return toV8(impl.get(), creationContext, isolate);
|
| }
|
|
|
| template<class CallbackInfo>
|
| -inline void v8SetReturnValue(const CallbackInfo& callbackInfo, PassRefPtr<TestException > impl, v8::Handle<v8::Object> creationContext)
|
| +inline void v8SetReturnValue(const CallbackInfo& callbackInfo, PassRefPtr<TestConstants > impl, v8::Handle<v8::Object> creationContext)
|
| {
|
| v8SetReturnValue(callbackInfo, impl.get(), creationContext);
|
| }
|
|
|
| template<class CallbackInfo>
|
| -inline void v8SetReturnValueForMainWorld(const CallbackInfo& callbackInfo, PassRefPtr<TestException > impl, v8::Handle<v8::Object> creationContext)
|
| +inline void v8SetReturnValueForMainWorld(const CallbackInfo& callbackInfo, PassRefPtr<TestConstants > impl, v8::Handle<v8::Object> creationContext)
|
| {
|
| v8SetReturnValueForMainWorld(callbackInfo, impl.get(), creationContext);
|
| }
|
|
|
| template<class CallbackInfo, class Wrappable>
|
| -inline void v8SetReturnValueFast(const CallbackInfo& callbackInfo, PassRefPtr<TestException > impl, Wrappable* wrappable)
|
| +inline void v8SetReturnValueFast(const CallbackInfo& callbackInfo, PassRefPtr<TestConstants > impl, Wrappable* wrappable)
|
| {
|
| v8SetReturnValueFast(callbackInfo, impl.get(), wrappable);
|
| }
|
|
|
| }
|
|
|
| -#endif // V8TestException_h
|
| +#endif // V8TestConstants_h
|
|
|