| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2009 Google Inc. All rights reserved. | 2 * Copyright (C) 2009 Google Inc. All rights reserved. |
| 3 * Copyright (C) 2012 Ericsson AB. All rights reserved. | 3 * Copyright (C) 2012 Ericsson AB. All rights reserved. |
| 4 * | 4 * |
| 5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
| 6 * modification, are permitted provided that the following conditions are | 6 * modification, are permitted provided that the following conditions are |
| 7 * met: | 7 * met: |
| 8 * | 8 * |
| 9 * * Redistributions of source code must retain the above copyright | 9 * * Redistributions of source code must retain the above copyright |
| 10 * notice, this list of conditions and the following disclaimer. | 10 * notice, this list of conditions and the following disclaimer. |
| (...skipping 691 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 702 void addHiddenValueToArray(v8::Handle<v8::Object>, v8::Local<v8::Value>, int cac
heIndex, v8::Isolate*); | 702 void addHiddenValueToArray(v8::Handle<v8::Object>, v8::Local<v8::Value>, int cac
heIndex, v8::Isolate*); |
| 703 void removeHiddenValueFromArray(v8::Handle<v8::Object>, v8::Local<v8::Value>, in
t cacheIndex, v8::Isolate*); | 703 void removeHiddenValueFromArray(v8::Handle<v8::Object>, v8::Local<v8::Value>, in
t cacheIndex, v8::Isolate*); |
| 704 void moveEventListenerToNewWrapper(v8::Handle<v8::Object>, EventListener* oldVal
ue, v8::Local<v8::Value> newValue, int cacheIndex, v8::Isolate*); | 704 void moveEventListenerToNewWrapper(v8::Handle<v8::Object>, EventListener* oldVal
ue, v8::Local<v8::Value> newValue, int cacheIndex, v8::Isolate*); |
| 705 | 705 |
| 706 // Converts a DOM object to a v8 value. | 706 // Converts a DOM object to a v8 value. |
| 707 // This is a no-inline version of toV8(). If you want to call toV8() | 707 // This is a no-inline version of toV8(). If you want to call toV8() |
| 708 // without creating #include cycles, you can use this function instead. | 708 // without creating #include cycles, you can use this function instead. |
| 709 // Each specialized implementation will be generated. | 709 // Each specialized implementation will be generated. |
| 710 template<typename T> | 710 template<typename T> |
| 711 v8::Handle<v8::Value> toV8NoInline(T* impl, v8::Handle<v8::Object> creationConte
xt, v8::Isolate*); | 711 v8::Handle<v8::Value> toV8NoInline(T* impl, v8::Handle<v8::Object> creationConte
xt, v8::Isolate*); |
| 712 template<typename T> | |
| 713 v8::Handle<v8::Value> toV8NoInline(T* impl, ExecutionContext* context) | |
| 714 { | |
| 715 v8::Isolate* isolate = toIsolate(context); | |
| 716 v8::Handle<v8::Context> v8Context = toV8Context(context, DOMWrapperWorld::cu
rrent(isolate)); | |
| 717 return toV8NoInline(impl, v8Context->Global(), isolate); | |
| 718 } | |
| 719 | 712 |
| 720 // Result values for platform object 'deleter' methods, | 713 // Result values for platform object 'deleter' methods, |
| 721 // http://www.w3.org/TR/WebIDL/#delete | 714 // http://www.w3.org/TR/WebIDL/#delete |
| 722 enum DeleteResult { | 715 enum DeleteResult { |
| 723 DeleteSuccess, | 716 DeleteSuccess, |
| 724 DeleteReject, | 717 DeleteReject, |
| 725 DeleteUnknownProperty | 718 DeleteUnknownProperty |
| 726 }; | 719 }; |
| 727 | 720 |
| 728 class V8IsolateInterruptor : public ThreadState::Interruptor { | 721 class V8IsolateInterruptor : public ThreadState::Interruptor { |
| (...skipping 28 matching lines...) Expand all Loading... |
| 757 v8::HandleScope m_handleScope; | 750 v8::HandleScope m_handleScope; |
| 758 v8::Handle<v8::Context> m_context; | 751 v8::Handle<v8::Context> m_context; |
| 759 v8::Context::Scope m_contextScope; | 752 v8::Context::Scope m_contextScope; |
| 760 RefPtr<DOMWrapperWorld> m_world; | 753 RefPtr<DOMWrapperWorld> m_world; |
| 761 OwnPtr<V8PerContextData> m_perContextData; | 754 OwnPtr<V8PerContextData> m_perContextData; |
| 762 }; | 755 }; |
| 763 | 756 |
| 764 } // namespace WebCore | 757 } // namespace WebCore |
| 765 | 758 |
| 766 #endif // V8Binding_h | 759 #endif // V8Binding_h |
| OLD | NEW |