diff --git a/src/js/quickjs/Makefile b/src/js/quickjs/Makefile index dd3e82b52..c92685939 100644 --- a/src/js/quickjs/Makefile +++ b/src/js/quickjs/Makefile @@ -1,7 +1,7 @@ top_builddir=../../.. include $(top_builddir)/Makefile.config -OBJS = attr.o attributes.o collection.o collection2.o console.o css.o customevent.o dataset.o document.o domparser.o domrect.o element.o event.o form.o forms.o fragment.o heartbeat.o history.o implementation.o input.o \ +OBJS = attr.o attributes.o collection.o console.o css.o customevent.o dataset.o document.o domparser.o domrect.o element.o event.o form.o forms.o fragment.o heartbeat.o history.o implementation.o input.o \ keyboard.o localstorage.o location.o mapa.o message.o navigator.o node.o nodelist.o nodelist2.o screen.o style.o text.o tokenlist.o unibar.o url.o urlsearchparams.o window.o xhr.o include $(top_srcdir)/Makefile.lib diff --git a/src/js/quickjs/collection.c b/src/js/quickjs/collection.c index 783e48687..bf880f223 100644 --- a/src/js/quickjs/collection.c +++ b/src/js/quickjs/collection.c @@ -40,10 +40,9 @@ js_htmlCollection_GetOpaque(JSValueConst this_val) REF_JS(this_val); return JS_GetOpaque(this_val, js_htmlCollection_class_id); - -// return attr_find_in_map_rev(map_rev_collections, this_val); } +#if 0 static void js_htmlCollection_SetOpaque(JSValueConst this_val, void *node) { @@ -58,6 +57,7 @@ js_htmlCollection_SetOpaque(JSValueConst this_val, void *node) } #endif } +#endif static void js_htmlColection_finalizer(JSRuntime *rt, JSValue val) diff --git a/src/js/quickjs/collection2.c b/src/js/quickjs/collection2.c index ed0d74b7f..df717f420 100644 --- a/src/js/quickjs/collection2.c +++ b/src/js/quickjs/collection2.c @@ -36,8 +36,6 @@ js_htmlCollection2_GetOpaque(JSValueConst this_val) REF_JS(this_val); return JS_GetOpaque(this_val, js_htmlCollection2_class_id); - -// return attr_find_in_map_rev(map_rev_collections, this_val); } static void @@ -346,7 +344,6 @@ getCollection2(JSContext *ctx, void *node) fprintf(stderr, "%s:%s\n", __FILE__, __FUNCTION__); #endif static int initialized; -// JSValue second; if (!initialized) { /* collection class */ @@ -354,13 +351,6 @@ getCollection2(JSContext *ctx, void *node) JS_NewClass(JS_GetRuntime(ctx), js_htmlCollection2_class_id, &js_htmlCollection2_class); initialized = 1; } -// second = attr_find_in_map(map_collections, node); - -// if (!JS_IsNull(second)) { -// JSValue r = JS_DupValue(ctx, second); -// -// RETURN_JS(r); -// } JSValue proto = JS_NewObjectClass(ctx, js_htmlCollection2_class_id); REF_JS(proto); diff --git a/src/js/quickjs/document.c b/src/js/quickjs/document.c index 7def084ab..35dd4c665 100644 --- a/src/js/quickjs/document.c +++ b/src/js/quickjs/document.c @@ -1236,7 +1236,6 @@ js_document_removeEventListener(JSContext *ctx, JSValueConst this_val, int argc, if (!doc_private) { return JS_NULL; } - dom_html_document *doc = (dom_html_document *)doc_private->node; //dom_node_ref(doc); if (argc < 2) { diff --git a/src/js/quickjs/element.c b/src/js/quickjs/element.c index 33c25ba04..859dac9da 100644 --- a/src/js/quickjs/element.c +++ b/src/js/quickjs/element.c @@ -1050,7 +1050,6 @@ js_element_set_property_nodeValue(JSContext *ctx, JSValueConst this_val, JSValue struct ecmascript_interpreter *interpreter = (struct ecmascript_interpreter *)JS_GetContextOpaque(ctx); dom_node *node = (dom_node *)(js_getopaque(this_val, js_element_class_id)); - JSValue r; if (!node) { return JS_UNDEFINED; diff --git a/src/js/quickjs/fragment.c b/src/js/quickjs/fragment.c index 3df9dc493..d72d1a284 100644 --- a/src/js/quickjs/fragment.c +++ b/src/js/quickjs/fragment.c @@ -523,7 +523,6 @@ js_fragment_set_property_nodeValue(JSContext *ctx, JSValueConst this_val, JSValu struct ecmascript_interpreter *interpreter = (struct ecmascript_interpreter *)JS_GetContextOpaque(ctx); dom_node *node = (dom_node *)(js_getopaque_fragment(this_val, js_fragment_class_id)); - JSValue r; if (!node) { return JS_UNDEFINED; diff --git a/src/js/quickjs/meson.build b/src/js/quickjs/meson.build index 21e3c5c7d..b05caa60c 100644 --- a/src/js/quickjs/meson.build +++ b/src/js/quickjs/meson.build @@ -1,4 +1,4 @@ -srcs += files('attr.c', 'attributes.c', 'collection.c', 'collection2.c', 'console.c', 'css.c', 'customevent.c', 'dataset.c', 'document.c', 'domparser.c', 'domrect.c', +srcs += files('attr.c', 'attributes.c', 'collection.c', 'console.c', 'css.c', 'customevent.c', 'dataset.c', 'document.c', 'domparser.c', 'domrect.c', 'element.c', 'event.c', 'form.c', 'forms.c', 'fragment.c', 'heartbeat.c', 'history.c', 'implementation.c', 'input.c', 'keyboard.c', 'localstorage.c', 'location.c', 'mapa.c', 'message.c', 'navigator.c', 'node.c', 'nodelist.c', 'nodelist2.c', 'screen.c', 'style.c', 'text.c', 'tokenlist.c', 'unibar.c', 'url.c', 'urlsearchparams.c', 'window.c', 'xhr.c') diff --git a/src/js/quickjs/text.c b/src/js/quickjs/text.c index 014de1fa6..79ae57216 100644 --- a/src/js/quickjs/text.c +++ b/src/js/quickjs/text.c @@ -522,7 +522,6 @@ js_text_set_property_nodeValue(JSContext *ctx, JSValueConst this_val, JSValue va REF_JS(this_val); struct ecmascript_interpreter *interpreter = (struct ecmascript_interpreter *)JS_GetContextOpaque(ctx); dom_node *node = (dom_node *)(js_getopaque_text(this_val, js_text_class_id)); - JSValue r; if (!node) { return JS_UNDEFINED;