1
0
mirror of https://github.com/rkd77/elinks.git synced 2024-12-04 14:46:47 -05:00

DOM TR: register/unregister row.

This commit is contained in:
Witold Filipczyk 2007-06-13 11:34:45 +02:00 committed by Witold Filipczyk
parent 0702ea97bd
commit f00433f233

View File

@ -6,6 +6,7 @@
#include "document/dom/ecmascript/spidermonkey.h"
#include "document/dom/ecmascript/spidermonkey/Node.h"
#include "document/dom/ecmascript/spidermonkey/html/HTMLTableElement.h"
#include "document/dom/ecmascript/spidermonkey/html/HTMLTableRowElement.h"
#include "dom/node.h"
@ -151,6 +152,7 @@ make_TR_object(JSContext *ctx, struct dom_node *node)
node->data.element.html_data = mem_calloc(1, sizeof(struct TR_struct));
if (node->data.element.html_data) {
node->ecmascript_obj = JS_NewObject(ctx, (JSClass *)&HTMLTableRowElement_class, o->HTMLElement_object, NULL);
register_row(node);
}
}
@ -159,6 +161,7 @@ done_TR_object(struct dom_node *node)
{
struct TR_struct *d = node->data.element.html_data;
unregister_row(node);
/* d->cells ? */
mem_free_if(d->align);
mem_free_if(d->bgcolor);