OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
3 * (C) 1999 Antti Koivisto (koivisto@kde.org) | 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) |
4 * (C) 2001 Peter Kelly (pmk@post.com) | 4 * (C) 2001 Peter Kelly (pmk@post.com) |
5 * (C) 2001 Dirk Mueller (mueller@kde.org) | 5 * (C) 2001 Dirk Mueller (mueller@kde.org) |
6 * (C) 2007 David Smith (catfish.man@gmail.com) | 6 * (C) 2007 David Smith (catfish.man@gmail.com) |
7 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2012, 2013 Apple Inc.
All rights reserved. | 7 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2012, 2013 Apple Inc.
All rights reserved. |
8 * (C) 2007 Eric Seidel (eric@webkit.org) | 8 * (C) 2007 Eric Seidel (eric@webkit.org) |
9 * | 9 * |
10 * This library is free software; you can redistribute it and/or | 10 * This library is free software; you can redistribute it and/or |
(...skipping 3215 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3226 | 3226 |
3227 ASSERT(!DOMDataStore::containsWrapper(this, isolate)); | 3227 ASSERT(!DOMDataStore::containsWrapper(this, isolate)); |
3228 | 3228 |
3229 ASSERT(!creationContext.IsEmpty()); | 3229 ASSERT(!creationContext.IsEmpty()); |
3230 v8::Handle<v8::Context> context = creationContext->CreationContext(); | 3230 v8::Handle<v8::Context> context = creationContext->CreationContext(); |
3231 | 3231 |
3232 if (!isUpgradedCustomElement() || DOMWrapperWorld::world(context).isIsolated
World()) | 3232 if (!isUpgradedCustomElement() || DOMWrapperWorld::world(context).isIsolated
World()) |
3233 return ContainerNode::wrap(creationContext, isolate); | 3233 return ContainerNode::wrap(creationContext, isolate); |
3234 | 3234 |
3235 const WrapperTypeInfo* wrapperType = wrapperTypeInfo(); | 3235 const WrapperTypeInfo* wrapperType = wrapperTypeInfo(); |
3236 v8::Handle<v8::Object> wrapper = V8DOMWrapper::createWrapper(creationContext
, wrapperType, toScriptWrappableBase(), isolate); | 3236 v8::Handle<v8::Object> wrapper = V8DOMWrapper::createWrapper(isolate, creati
onContext, wrapperType, toScriptWrappableBase()); |
3237 if (wrapper.IsEmpty()) | 3237 if (wrapper.IsEmpty()) |
3238 return v8::Handle<v8::Object>(); | 3238 return v8::Handle<v8::Object>(); |
3239 | 3239 |
3240 V8PerContextData* perContextData = V8PerContextData::from(context); | 3240 V8PerContextData* perContextData = V8PerContextData::from(context); |
3241 if (!perContextData) | 3241 if (!perContextData) |
3242 return wrapper; | 3242 return wrapper; |
3243 | 3243 |
3244 CustomElementBinding* binding = perContextData->customElementBinding(customE
lementDefinition()); | 3244 CustomElementBinding* binding = perContextData->customElementBinding(customE
lementDefinition()); |
3245 | 3245 |
3246 wrapper->SetPrototype(binding->prototype()); | 3246 wrapper->SetPrototype(binding->prototype()); |
3247 | 3247 |
3248 return V8DOMWrapper::associateObjectWithWrapper(isolate, this, wrapperType,
wrapper); | 3248 return V8DOMWrapper::associateObjectWithWrapper(isolate, this, wrapperType,
wrapper); |
3249 } | 3249 } |
3250 | 3250 |
3251 } // namespace blink | 3251 } // namespace blink |
OLD | NEW |