| 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 940 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 951 {"Node14", TestInterfaceV8Internal::Node14AttributeGetterCallback, TestI
nterfaceV8Internal::Node14AttributeSetterCallback, 0, 0, 0, static_cast<v8::Acce
ssControl>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::None), 0 /* on i
nstance */}; | 951 {"Node14", TestInterfaceV8Internal::Node14AttributeGetterCallback, TestI
nterfaceV8Internal::Node14AttributeSetterCallback, 0, 0, 0, static_cast<v8::Acce
ssControl>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::None), 0 /* on i
nstance */}; |
| 952 V8DOMConfiguration::installAttribute(instanceTemplate, prototypeTemplate
, attributeConfiguration, isolate); | 952 V8DOMConfiguration::installAttribute(instanceTemplate, prototypeTemplate
, attributeConfiguration, isolate); |
| 953 } | 953 } |
| 954 if (ContextFeatures::condition16Enabled(impl->document())) { | 954 if (ContextFeatures::condition16Enabled(impl->document())) { |
| 955 static const V8DOMConfiguration::AttributeConfiguration attributeConfigu
ration =\ | 955 static const V8DOMConfiguration::AttributeConfiguration attributeConfigu
ration =\ |
| 956 {"Node15", TestInterfaceV8Internal::Node15AttributeGetterCallback, TestI
nterfaceV8Internal::Node15AttributeSetterCallback, 0, 0, 0, static_cast<v8::Acce
ssControl>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::None), 0 /* on i
nstance */}; | 956 {"Node15", TestInterfaceV8Internal::Node15AttributeGetterCallback, TestI
nterfaceV8Internal::Node15AttributeSetterCallback, 0, 0, 0, static_cast<v8::Acce
ssControl>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::None), 0 /* on i
nstance */}; |
| 957 V8DOMConfiguration::installAttribute(instanceTemplate, prototypeTemplate
, attributeConfiguration, isolate); | 957 V8DOMConfiguration::installAttribute(instanceTemplate, prototypeTemplate
, attributeConfiguration, isolate); |
| 958 } | 958 } |
| 959 } | 959 } |
| 960 | 960 |
| 961 ActiveDOMObject* V8TestInterface::toActiveDOMObject(v8::Handle<v8::Object> objec
t) | 961 ActiveDOMObject* V8TestInterface::toActiveDOMObject(v8::Handle<v8::Object> wrapp
er) |
| 962 { | 962 { |
| 963 return toNative(object); | 963 return toNative(wrapper); |
| 964 } | 964 } |
| 965 | 965 |
| 966 v8::Handle<v8::Object> V8TestInterface::createWrapper(PassRefPtr<TestInterface>
impl, v8::Handle<v8::Object> creationContext, v8::Isolate* isolate) | 966 v8::Handle<v8::Object> V8TestInterface::createWrapper(PassRefPtr<TestInterface>
impl, v8::Handle<v8::Object> creationContext, v8::Isolate* isolate) |
| 967 { | 967 { |
| 968 ASSERT(impl); | 968 ASSERT(impl); |
| 969 ASSERT(!DOMDataStore::containsWrapper<V8TestInterface>(impl.get(), isolate))
; | 969 ASSERT(!DOMDataStore::containsWrapper<V8TestInterface>(impl.get(), isolate))
; |
| 970 if (ScriptWrappable::wrapperCanBeStoredInObject(impl.get())) { | 970 if (ScriptWrappable::wrapperCanBeStoredInObject(impl.get())) { |
| 971 const WrapperTypeInfo* actualInfo = ScriptWrappable::getTypeInfoFromObje
ct(impl.get()); | 971 const WrapperTypeInfo* actualInfo = ScriptWrappable::getTypeInfoFromObje
ct(impl.get()); |
| 972 // Might be a XXXConstructor::wrapperTypeInfo instead of an XXX::wrapper
TypeInfo. These will both have | 972 // Might be a XXXConstructor::wrapperTypeInfo instead of an XXX::wrapper
TypeInfo. These will both have |
| 973 // the same object de-ref functions, though, so use that as the basis of
the check. | 973 // the same object de-ref functions, though, so use that as the basis of
the check. |
| (...skipping 10 matching lines...) Expand all Loading... |
| 984 } | 984 } |
| 985 | 985 |
| 986 void V8TestInterface::derefObject(void* object) | 986 void V8TestInterface::derefObject(void* object) |
| 987 { | 987 { |
| 988 fromInternalPointer(object)->deref(); | 988 fromInternalPointer(object)->deref(); |
| 989 } | 989 } |
| 990 | 990 |
| 991 } // namespace WebCore | 991 } // namespace WebCore |
| 992 | 992 |
| 993 #endif // ENABLE(Condition1) || ENABLE(Condition2) | 993 #endif // ENABLE(Condition1) || ENABLE(Condition2) |
| OLD | NEW |