diff options
Diffstat (limited to 'src/uscxml/plugins/datamodel/ecmascript/v8/dom/V8DOM.h')
-rw-r--r-- | src/uscxml/plugins/datamodel/ecmascript/v8/dom/V8DOM.h | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/src/uscxml/plugins/datamodel/ecmascript/v8/dom/V8DOM.h b/src/uscxml/plugins/datamodel/ecmascript/v8/dom/V8DOM.h index 122a457..10528e8 100644 --- a/src/uscxml/plugins/datamodel/ecmascript/v8/dom/V8DOM.h +++ b/src/uscxml/plugins/datamodel/ecmascript/v8/dom/V8DOM.h @@ -9,12 +9,21 @@ static void jsDestructor(v8::Persistent<v8::Value> object, void* data) { \ v8::HandleScope handleScope; \ type* thing = static_cast<type*>(v8::Local<v8::External>::Cast(object->ToObject()->GetInternalField(0))->Value()); \ - delete thing->arabicaThis; \ + delete thing->nativeObj; \ delete thing; \ object.Dispose(); \ object.Clear(); \ } +#define V8_DESTRUCTOR_KEEP_WRAPPED(type) \ +static void jsDestructor(v8::Persistent<v8::Value> object, void* data) { \ +v8::HandleScope handleScope; \ +type* thing = static_cast<type*>(v8::Local<v8::External>::Cast(object->ToObject()->GetInternalField(0))->Value()); \ +delete thing; \ +object.Dispose(); \ +object.Clear(); \ +} + namespace Arabica { namespace DOM { |