mirror of
https://github.com/rkd77/elinks.git
synced 2024-09-12 00:34:47 -04:00
DOM: SpiderMonkey's DOM implementation started.
Added placeholders of functions and properties.
This commit is contained in:
parent
a2f18bb6fc
commit
df573e56e3
@ -2,5 +2,6 @@ top_builddir=../../..
|
||||
include $(top_builddir)/Makefile.config
|
||||
|
||||
OBJS = renderer.o
|
||||
SUBDIRS-$(CONFIG_ECMASCRIPT) += ecmascript
|
||||
|
||||
include $(top_srcdir)/Makefile.lib
|
||||
|
8
src/document/dom/ecmascript/Makefile
Normal file
8
src/document/dom/ecmascript/Makefile
Normal file
@ -0,0 +1,8 @@
|
||||
top_builddir=../../../..
|
||||
include $(top_builddir)/Makefile.config
|
||||
|
||||
INCLUDES += $(SPIDERMONKEY_CFLAGS)
|
||||
SUBDIRS-$(CONFIG_SPIDERMONKEY) += spidermonkey
|
||||
OBJS-$(CONFIG_SPIDERMONKEY) += spidermonkey.o
|
||||
|
||||
include $(top_srcdir)/Makefile.lib
|
36
src/document/dom/ecmascript/spidermonkey.c
Normal file
36
src/document/dom/ecmascript/spidermonkey.c
Normal file
@ -0,0 +1,36 @@
|
||||
/* SpiderMonkey's DOM implementation */
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include "elinks.h"
|
||||
|
||||
#include "document/dom/ecmascript/spidermonkey.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/Attr.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/CDATASection.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/CharacterData.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/Comment.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/Document.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/DocumentFragment.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/DocumentType.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/DOMConfiguration.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/DOMError.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/DOMErrorHandler.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/DOMException.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/DOMImplementation.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/DOMImplementationList.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/DOMImplementationRegistry.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/DOMImplementationSource.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/DOMLocator.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/DOMStringList.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/Element.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/Entity.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/EntityReference.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/NamedNodeMap.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/NameList.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/Node.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/Notation.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/ProcessingInstruction.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/Text.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/TypeInfo.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/UserDataHandler.h"
|
6
src/document/dom/ecmascript/spidermonkey.h
Normal file
6
src/document/dom/ecmascript/spidermonkey.h
Normal file
@ -0,0 +1,6 @@
|
||||
#ifndef EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_H
|
||||
#define EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_H
|
||||
|
||||
#include "document/dom/ecmascript/spidermonkey/props.h"
|
||||
|
||||
#endif
|
74
src/document/dom/ecmascript/spidermonkey/Attr.c
Normal file
74
src/document/dom/ecmascript/spidermonkey/Attr.c
Normal file
@ -0,0 +1,74 @@
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include "elinks.h"
|
||||
#include "document/dom/ecmascript/spidermonkey.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/Attr.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/Node.h"
|
||||
|
||||
static JSBool
|
||||
Attr_getProperty(JSContext *ctx, JSObject *obj, jsval id, jsval *vp)
|
||||
{
|
||||
if (!JSVAL_IS_INT(id))
|
||||
return JS_TRUE;
|
||||
|
||||
switch (JSVAL_TO_INT(id)) {
|
||||
case JSP_DOM_NAME:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_SPECIFIED:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_VALUE:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_OWNER_ELEMENT:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_SCHEMA_TYPE_INFO:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_IS_ID:
|
||||
/* Write me! */
|
||||
break;
|
||||
default:
|
||||
return Node_getProperty(ctx, obj, id, vp);
|
||||
}
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Attr_setProperty(JSContext *ctx, JSObject *obj, jsval id, jsval *vp)
|
||||
{
|
||||
if (!JSVAL_IS_INT(id))
|
||||
return JS_TRUE;
|
||||
|
||||
switch (JSVAL_TO_INT(id)) {
|
||||
case JSP_DOM_VALUE:
|
||||
/* Write me! */
|
||||
break;
|
||||
default:
|
||||
return Node_setProperty(ctx, obj, id, vp);
|
||||
}
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
const JSPropertySpec Attr_props[] = {
|
||||
{ "name", JSP_DOM_NAME, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "specified", JSP_DOM_SPECIFIED, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "value", JSP_DOM_VALUE, JSPROP_ENUMERATE },
|
||||
{ "ownerElement", JSP_DOM_OWNER_ELEMENT, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "schemaTypeInfo", JSP_DOM_SCHEMA_TYPE_INFO,JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "isId", JSP_DOM_IS_ID, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ NULL }
|
||||
};
|
||||
|
||||
const JSClass Attr_class = {
|
||||
"Attr",
|
||||
JSCLASS_HAS_PRIVATE,
|
||||
JS_PropertyStub, JS_PropertyStub,
|
||||
Attr_getProperty, Attr_setProperty,
|
||||
JS_EnumerateStub, JS_ResolveStub, JS_ConvertStub, JS_FinalizeStub
|
||||
};
|
||||
|
9
src/document/dom/ecmascript/spidermonkey/Attr.h
Normal file
9
src/document/dom/ecmascript/spidermonkey/Attr.h
Normal file
@ -0,0 +1,9 @@
|
||||
#ifndef EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_ATTR_H
|
||||
#define EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_ATTR_H
|
||||
|
||||
#include "ecmascript/spidermonkey/util.h"
|
||||
|
||||
extern const JSClass Attr_class;
|
||||
extern const JSPropertySpec Attr_props[];
|
||||
|
||||
#endif
|
18
src/document/dom/ecmascript/spidermonkey/CDATASection.c
Normal file
18
src/document/dom/ecmascript/spidermonkey/CDATASection.c
Normal file
@ -0,0 +1,18 @@
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include "elinks.h"
|
||||
#include "document/dom/ecmascript/spidermonkey.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/CDATASection.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/CharacterData.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/Text.h"
|
||||
|
||||
const JSClass CDATASection_class = {
|
||||
"CDATASection",
|
||||
JSCLASS_HAS_PRIVATE,
|
||||
JS_PropertyStub, JS_PropertyStub,
|
||||
Text_getProperty, CharacterData_setProperty,
|
||||
JS_EnumerateStub, JS_ResolveStub, JS_ConvertStub, JS_FinalizeStub
|
||||
};
|
||||
|
9
src/document/dom/ecmascript/spidermonkey/CDATASection.h
Normal file
9
src/document/dom/ecmascript/spidermonkey/CDATASection.h
Normal file
@ -0,0 +1,9 @@
|
||||
#ifndef EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_CDATASECTION_H
|
||||
#define EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_CDATASECTION_H
|
||||
|
||||
#include "ecmascript/spidermonkey/util.h"
|
||||
|
||||
extern const JSClass CDATASection_class;
|
||||
|
||||
#endif
|
||||
|
105
src/document/dom/ecmascript/spidermonkey/CharacterData.c
Normal file
105
src/document/dom/ecmascript/spidermonkey/CharacterData.c
Normal file
@ -0,0 +1,105 @@
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include "elinks.h"
|
||||
#include "document/dom/ecmascript/spidermonkey.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/CharacterData.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/Node.h"
|
||||
|
||||
JSBool
|
||||
Character_getProperty(JSContext *ctx, JSObject *obj, jsval id, jsval *vp)
|
||||
{
|
||||
if (!JSVAL_IS_INT(id))
|
||||
return JS_TRUE;
|
||||
switch (JSVAL_TO_INT(id)) {
|
||||
case JSP_DOM_DATA:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_LENGTH:
|
||||
/* Write me! */
|
||||
break;
|
||||
default:
|
||||
return Node_getProperty(ctx, obj, id, vp);
|
||||
}
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
JSBool
|
||||
Character_setProperty(JSContext *ctx, JSObject *obj, jsval id, jsval *vp)
|
||||
{
|
||||
if (!JSVAL_IS_INT(id))
|
||||
return JS_TRUE;
|
||||
switch (JSVAL_TO_INT(id)) {
|
||||
case JSP_DOM_DATA:
|
||||
/* Write me! */
|
||||
break;
|
||||
default:
|
||||
return Node_setProperty(ctx, obj, id, vp);
|
||||
}
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
CharacterData_substringData(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
CharacterData_appendData(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
CharacterData_insertData(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
CharacterData_deleteData(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
CharacterData_replaceData(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
const JSPropertySpec CharacterData_props[] = {
|
||||
{ "data", JSP_DOM_DATA, JSPROP_ENUMERATE },
|
||||
{ "length", JSP_DOM_LENGTH, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ NULL }
|
||||
};
|
||||
|
||||
const JSFunctionSpec CharacterData_funcs[] = {
|
||||
{ "substringData", CharacterData_substringData, 2 },
|
||||
{ "appendData", CharacterData_appendData, 1 },
|
||||
{ "insertData", CharacterData_insertData, 2 },
|
||||
{ "deleteData", CharacterData_deleteData, 2 },
|
||||
{ "replaceData", CharacterData_replaceData, 3 },
|
||||
{ NULL }
|
||||
};
|
||||
|
||||
const JSClass CharacterData_class = {
|
||||
"CharacterData",
|
||||
JSCLASS_HAS_PRIVATE,
|
||||
JS_PropertyStub, JS_PropertyStub,
|
||||
CharacterData_getProperty, CharacterData_setProperty,
|
||||
JS_EnumerateStub, JS_ResolveStub, JS_ConvertStub, JS_FinalizeStub
|
||||
};
|
||||
|
14
src/document/dom/ecmascript/spidermonkey/CharacterData.h
Normal file
14
src/document/dom/ecmascript/spidermonkey/CharacterData.h
Normal file
@ -0,0 +1,14 @@
|
||||
#ifndef EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_CHARACTERDATA_H
|
||||
#define EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_CHARACTERDATA_H
|
||||
|
||||
#include "ecmascript/spidermonkey/util.h"
|
||||
|
||||
extern const JSClass CharacterData_class;
|
||||
extern const JSFunctionSpec CharacterData_funcs[];
|
||||
extern const JSPropertySpec CharacterData_props[];
|
||||
|
||||
JSBool CharacterData_getProperty(JSContext *ctx, JSObject *obj, jsval id, jsval *vp);
|
||||
JSBool CharacterData_setProperty(JSContext *ctx, JSObject *obj, jsval id, jsval *vp);
|
||||
|
||||
#endif
|
||||
|
18
src/document/dom/ecmascript/spidermonkey/Comment.c
Normal file
18
src/document/dom/ecmascript/spidermonkey/Comment.c
Normal file
@ -0,0 +1,18 @@
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include "elinks.h"
|
||||
|
||||
#include "document/dom/ecmascript/spidermonkey.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/CharacterData.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/Comment.h"
|
||||
|
||||
const JSClass Comment_class = {
|
||||
"Comment",
|
||||
JSCLASS_HAS_PRIVATE,
|
||||
JS_PropertyStub, JS_PropertyStub,
|
||||
CharacterData_getProperty, CharacterData_setProperty,
|
||||
JS_EnumerateStub, JS_ResolveStub, JS_ConvertStub, JS_FinalizeStub
|
||||
};
|
||||
|
8
src/document/dom/ecmascript/spidermonkey/Comment.h
Normal file
8
src/document/dom/ecmascript/spidermonkey/Comment.h
Normal file
@ -0,0 +1,8 @@
|
||||
#ifndef EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_COMMENT_H
|
||||
#define EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_COMMENT_H
|
||||
|
||||
#include "ecmascript/spidermonkey/util.h"
|
||||
|
||||
extern const JSClass Comment_class;
|
||||
|
||||
#endif
|
67
src/document/dom/ecmascript/spidermonkey/DOMConfiguration.c
Normal file
67
src/document/dom/ecmascript/spidermonkey/DOMConfiguration.c
Normal file
@ -0,0 +1,67 @@
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include "elinks.h"
|
||||
#include "document/dom/ecmascript/spidermonkey.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/DOMConfiguration.h"
|
||||
|
||||
static JSBool
|
||||
DOMConfiguration_getProperty(JSContext *ctx, JSObject *obj, jsval id, jsval *vp)
|
||||
{
|
||||
if (!JSVAL_IS_INT(id))
|
||||
return JS_TRUE;
|
||||
switch (JSVAL_TO_INT(id)) {
|
||||
case JSP_DOM_PARAMETER_NAMES:
|
||||
/* Write me! */
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
DOMConfiguration_setParameter(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
DOMConfiguration_getParameter(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
DOMConfiguration_canSetParameter(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
const JSPropertySpec DOMConfiguration_props[] = {
|
||||
{ "parameterNames", JSP_DOM_PARAMETER_NAMES, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ NULL }
|
||||
};
|
||||
|
||||
const JSFunctionSpec DOMConfiguration_funcs[] = {
|
||||
{ "setParameter", DOMConfiguration_setParameter, 2 },
|
||||
{ "getParameter", DOMConfiguration_getParameter, 1 },
|
||||
{ "canSetParameter", DOMConfiguration_canSetParameter, 2 },
|
||||
{ NULL }
|
||||
};
|
||||
|
||||
const JSClass DOMConfiguration_class = {
|
||||
"DOMConfiguration",
|
||||
JSCLASS_HAS_PRIVATE,
|
||||
JS_PropertyStub, JS_PropertyStub,
|
||||
DOMConfiguration_getProperty, JS_PropertyStub,
|
||||
JS_EnumerateStub, JS_ResolveStub, JS_ConvertStub, JS_FinalizeStub
|
||||
};
|
||||
|
11
src/document/dom/ecmascript/spidermonkey/DOMConfiguration.h
Normal file
11
src/document/dom/ecmascript/spidermonkey/DOMConfiguration.h
Normal file
@ -0,0 +1,11 @@
|
||||
#ifndef EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_DOMCONFIGURATION_H
|
||||
#define EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_DOMCONFIGURATION_H
|
||||
|
||||
#include "ecmascript/spidermonkey/util.h"
|
||||
|
||||
extern const JSClass DOMConfiguration_class;
|
||||
extern const JSFunctionSpec DOMConfiguration_funcs[];
|
||||
extern const JSPropertySpec DOMConfiguration_props[];
|
||||
|
||||
#endif
|
||||
|
56
src/document/dom/ecmascript/spidermonkey/DOMError.c
Normal file
56
src/document/dom/ecmascript/spidermonkey/DOMError.c
Normal file
@ -0,0 +1,56 @@
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include "elinks.h"
|
||||
#include "document/dom/ecmascript/spidermonkey.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/DOMError.h"
|
||||
|
||||
static JSBool
|
||||
DOMError_getProperty(JSContext *ctx, JSObject *obj, jsval id, jsval *vp)
|
||||
{
|
||||
if (!JSVAL_IS_INT(id))
|
||||
return JS_TRUE;
|
||||
switch (JSVAL_TO_INT(id)) {
|
||||
case JSP_DOM_SEVERITY:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_MESSAGE:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_TYPE:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_RELATED_EXCEPTION:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_RELATED_DATA:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_LOCATION:
|
||||
/* Write me! */
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
const JSPropertySpec DOMError_props[] = {
|
||||
{ "severity", JSP_DOM_SEVERITY, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "message", JSP_DOM_MESSAGE, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "type", JSP_DOM_TYPE, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "relatedException", JSP_DOM_RELATED_EXCEPTION, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "relatedData", JSP_DOM_RELATED_DATA, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "location", JSP_DOM_LOCATION, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ NULL }
|
||||
};
|
||||
|
||||
const JSClass DOMError_class = {
|
||||
"DOMError",
|
||||
JSCLASS_HAS_PRIVATE,
|
||||
JS_PropertyStub, JS_PropertyStub,
|
||||
DOMError_getProperty, JS_PropertyStub,
|
||||
JS_EnumerateStub, JS_ResolveStub, JS_ConvertStub, JS_FinalizeStub
|
||||
};
|
||||
|
9
src/document/dom/ecmascript/spidermonkey/DOMError.h
Normal file
9
src/document/dom/ecmascript/spidermonkey/DOMError.h
Normal file
@ -0,0 +1,9 @@
|
||||
#ifndef EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_DOMERROR_H
|
||||
#define EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_DOMERROR_H
|
||||
|
||||
#include "ecmascript/spidermonkey/util.h"
|
||||
|
||||
extern const JSClass DOMError_class;
|
||||
extern const JSPropertySpec DOMError_props[];
|
||||
|
||||
#endif
|
10
src/document/dom/ecmascript/spidermonkey/DOMErrorHandler.c
Normal file
10
src/document/dom/ecmascript/spidermonkey/DOMErrorHandler.c
Normal file
@ -0,0 +1,10 @@
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include "elinks.h"
|
||||
#include "document/dom/ecmascript/spidermonkey.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/DOMErrorHandler.h"
|
||||
|
||||
/* I don't know what to write here yet. -- witekfl */
|
||||
|
@ -0,0 +1,7 @@
|
||||
#ifndef EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_DOMERRORHANDLER_H
|
||||
#define EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_DOMERRORHANDLER_H
|
||||
|
||||
#include "ecmascript/spidermonkey/util.h"
|
||||
|
||||
#endif
|
||||
|
51
src/document/dom/ecmascript/spidermonkey/DOMException.c
Normal file
51
src/document/dom/ecmascript/spidermonkey/DOMException.c
Normal file
@ -0,0 +1,51 @@
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include "elinks.h"
|
||||
#include "document/dom/ecmascript/spidermonkey.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/DOMException.h"
|
||||
|
||||
static JSBool
|
||||
DOMException_getProperty(JSContext *ctx, JSObject *obj, jsval id, jsval *vp)
|
||||
{
|
||||
if (!JSVAL_IS_INT(id))
|
||||
return JS_TRUE;
|
||||
switch (JSVAL_TO_INT(id)) {
|
||||
case JSP_DOM_CODE:
|
||||
/* Write me! */
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
DOMException_setProperty(JSContext *ctx, JSObject *obj, jsval id, jsval *vp)
|
||||
{
|
||||
if (!JSVAL_IS_INT(id))
|
||||
return JS_TRUE;
|
||||
switch (JSVAL_TO_INT(id)) {
|
||||
case JSP_DOM_CODE:
|
||||
/* Write me! */
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
const JSPropertySpec DOMException_props[] = {
|
||||
{ "code", JSP_DOM_CODE, JSPROP_ENUMERATE },
|
||||
{ NULL }
|
||||
};
|
||||
|
||||
const JSClass DOMException_class = {
|
||||
"DOMException",
|
||||
JSCLASS_HAS_PRIVATE,
|
||||
JS_PropertyStub, JS_PropertyStub,
|
||||
DOMException_getProperty, DOMException_setProperty,
|
||||
JS_EnumerateStub, JS_ResolveStub, JS_ConvertStub, JS_FinalizeStub
|
||||
};
|
||||
|
9
src/document/dom/ecmascript/spidermonkey/DOMException.h
Normal file
9
src/document/dom/ecmascript/spidermonkey/DOMException.h
Normal file
@ -0,0 +1,9 @@
|
||||
#ifndef EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_DOMEXCEPTION_H
|
||||
#define EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_DOMEXCEPTION_H
|
||||
|
||||
#include "ecmascript/spidermonkey/util.h"
|
||||
|
||||
extern const JSClass DOMException_class;
|
||||
extern const JSPropertySpec DOMException_props[];
|
||||
|
||||
#endif
|
56
src/document/dom/ecmascript/spidermonkey/DOMImplementation.c
Normal file
56
src/document/dom/ecmascript/spidermonkey/DOMImplementation.c
Normal file
@ -0,0 +1,56 @@
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include "elinks.h"
|
||||
#include "document/dom/ecmascript/spidermonkey.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/DOMImplementation.h"
|
||||
|
||||
static JSBool
|
||||
DOMImplementation_hasFeature(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
DOMImplementation_createDocumentType(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
DOMImplementation_createDocument(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
DOMImplementation_getFeature(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
const JSFunctionSpec DOMImplementation_funcs[] = {
|
||||
{ "hasFeature", DOMImplementation_hasFeature, 2 },
|
||||
{ "createDocumentType", DOMImplementation_createDocumentType, 3 },
|
||||
{ "createDocument", DOMImplementation_createDocument, 3 },
|
||||
{ "getFeature", DOMImplementation_getFeature, 2 },
|
||||
{ NULL }
|
||||
};
|
||||
|
||||
const JSClass DOMImplementation_class = {
|
||||
"DOMImplementation",
|
||||
JSCLASS_HAS_PRIVATE,
|
||||
JS_PropertyStub, JS_PropertyStub,
|
||||
JS_PropertyStub, JS_PropertyStub,
|
||||
JS_EnumerateStub, JS_ResolveStub, JS_ConvertStub, JS_FinalizeStub
|
||||
};
|
||||
|
10
src/document/dom/ecmascript/spidermonkey/DOMImplementation.h
Normal file
10
src/document/dom/ecmascript/spidermonkey/DOMImplementation.h
Normal file
@ -0,0 +1,10 @@
|
||||
#ifndef EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_DOMIMPLEMENTATION_H
|
||||
#define EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_DOMIMPLEMENTATION_H
|
||||
|
||||
#include "ecmascript/spidermonkey/util.h"
|
||||
|
||||
extern const JSClass DOMImplementation_class;
|
||||
extern const JSFunctionSpec DOMImplementation_funcs[];
|
||||
|
||||
#endif
|
||||
|
@ -0,0 +1,50 @@
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include "elinks.h"
|
||||
|
||||
#include "document/dom/ecmascript/spidermonkey.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/DOMImplementationList.h"
|
||||
|
||||
static JSBool
|
||||
DOMImplementationList_getProperty(JSContext *ctx, JSObject *obj, jsval id, jsval *vp)
|
||||
{
|
||||
if (!JSVAL_IS_INT(id))
|
||||
return JS_TRUE;
|
||||
switch (JSVAL_TO_INT(id)) {
|
||||
case JSP_DOM_LENGTH:
|
||||
/* Write me! */
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
DOMImplementationList_item(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
const JSPropertySpec DOMImplementationList_props[] = {
|
||||
{ "length", JSP_DOM_LENGTH, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ NULL }
|
||||
};
|
||||
|
||||
const JSFunctionSpec DOMIMplementationList_funcs[] = {
|
||||
{ "item", DOMImplementationList_item, 1 },
|
||||
{ NULL }
|
||||
};
|
||||
|
||||
const JSClass DOMImplementationList_class = {
|
||||
"DOMImplementationList",
|
||||
JSCLASS_HAS_PRIVATE,
|
||||
JS_PropertyStub, JS_PropertyStub,
|
||||
DOMImplementationList_getProperty, JS_PropertyStub,
|
||||
JS_EnumerateStub, JS_ResolveStub, JS_ConvertStub, JS_FinalizeStub
|
||||
};
|
||||
|
@ -0,0 +1,11 @@
|
||||
#ifndef EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_DOMIMPLEMENTATIONLIST_H
|
||||
#define EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_DOMIMPLEMENTATIONLIST_H
|
||||
|
||||
#include "ecmascript/spidermonkey/util.h"
|
||||
|
||||
extern const JSClass DOMImplementationList_class;
|
||||
extern const JSFunctionSpec DOMImplementationList_funcs[];
|
||||
extern const JSPropertySpec DOMImplementationList_props[];
|
||||
|
||||
#endif
|
||||
|
@ -0,0 +1,40 @@
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include "elinks.h"
|
||||
|
||||
#include "document/dom/ecmascript/spidermonkey.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/DOMImplementationRegistry.h"
|
||||
|
||||
static JSBool
|
||||
DOMImplementationRegistry_getDOMImplementation(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
|
||||
static JSBool
|
||||
DOMImplementationRegistry_getDOMImplementationList(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
const JSFunctionSpec DOMImplementationRegistry_funcs[] = {
|
||||
{ "getDOMImplementation", DOMImplementationRegistry_getDOMImplementation, 1 },
|
||||
{ "getDOMImplementationList", DOMImplementationRegistry_getDOMImplementationList, 1 },
|
||||
{ NULL }
|
||||
};
|
||||
|
||||
const JSClass DOMIMplementationRegistry_class = {
|
||||
"DOMImplementationRegistry",
|
||||
JSCLASS_HAS_PRIVATE,
|
||||
JS_PropertyStub, JS_PropertyStub,
|
||||
JS_PropertyStub, JS_PropertyStub,
|
||||
JS_EnumerateStub, JS_ResolveStub, JS_ConvertStub, JS_FinalizeStub
|
||||
};
|
||||
|
@ -0,0 +1,10 @@
|
||||
#ifndef EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_DOMIMPLEMENTATIONREGISTRY_H
|
||||
#define EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_DOMIMPLEMENTATIONREGISTRY_H
|
||||
|
||||
#include "ecmascript/spidermonkey/util.h"
|
||||
|
||||
extern const JSClass DOMImplementationRegistry_class;
|
||||
extern const JSFunctionSpec DOMImplementationRegistry_funcs[];
|
||||
|
||||
#endif
|
||||
|
@ -0,0 +1,39 @@
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include "elinks.h"
|
||||
|
||||
#include "document/dom/ecmascript/spidermonkey.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/DOMImplementationSource.h"
|
||||
|
||||
static JSBool
|
||||
DOMImplementationSource_getDOMImplementation(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
DOMImplementationSource_getDOMImplementationList(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
const JSFunctionSpec DOMImplementationSource_funcs[] = {
|
||||
{ "getDOMImplementation", DOMImplementationSource_getDOMImplementation, 1 },
|
||||
{ "getDOMImplementationList", DOMImplementationSource_getDOMImplementationList, 1 },
|
||||
{ NULL }
|
||||
};
|
||||
|
||||
const JSClass DOMImplementationSource_class = {
|
||||
"DOMImplementationSource",
|
||||
JSCLASS_HAS_PRIVATE,
|
||||
JS_PropertyStub, JS_PropertyStub,
|
||||
JS_PropertyStub, JS_PropertyStub,
|
||||
JS_EnumerateStub, JS_ResolveStub, JS_ConvertStub, JS_FinalizeStub
|
||||
};
|
||||
|
@ -0,0 +1,10 @@
|
||||
#ifndef EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_DOMIMPLEMENTATIONSOURCE_H
|
||||
#define EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_DOMIMPLEMENTATIONSOURCE_H
|
||||
|
||||
#include "ecmascript/spidermonkey/util.h"
|
||||
|
||||
extern const JSClass DOMImplementationSource_class;
|
||||
extern const JSFunctionSpec DOMImplementationSource_funcs[];
|
||||
|
||||
#endif
|
||||
|
57
src/document/dom/ecmascript/spidermonkey/DOMLocator.c
Normal file
57
src/document/dom/ecmascript/spidermonkey/DOMLocator.c
Normal file
@ -0,0 +1,57 @@
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include "elinks.h"
|
||||
|
||||
#include "document/dom/ecmascript/spidermonkey.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/DOMLocator.h"
|
||||
|
||||
static JSBool
|
||||
DOMLocator_getProperty(JSContext *ctx, JSObject *obj, jsval id, jsval *vp)
|
||||
{
|
||||
if (!JSVAL_IS_INT(id))
|
||||
return JS_TRUE;
|
||||
switch (JSVAL_TO_INT(id)) {
|
||||
case JSP_DOM_LINE_NUMBER:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_COLUMN_NUMBER:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_BYTE_OFFSET:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_UTF16_OFFSET:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_RELATED_NODE:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_URI:
|
||||
/* Write me! */
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
const JSPropertySpec DOMLocator_props[] = {
|
||||
{ "lineNumber", JSP_DOM_LINE_NUMBER, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "columnNumber", JSP_DOM_COLUMN_NUMBER, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "byteOffset", JSP_DOM_BYTE_OFFSET, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "utf16Offset", JSP_DOM_UTF16_OFFSET, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "relatedNode", JSP_DOM_RELATED_NODE, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "uri", JSP_DOM_URI, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ NULL }
|
||||
};
|
||||
|
||||
const JSClass DOMLocator_class = {
|
||||
"DOMLocator",
|
||||
JSCLASS_HAS_PRIVATE,
|
||||
JS_PropertyStub, JS_PropertyStub,
|
||||
DOMLocator_getProperty, JS_PropertyStub,
|
||||
JS_EnumerateStub, JS_ResolveStub, JS_ConvertStub, JS_FinalizeStub
|
||||
};
|
||||
|
10
src/document/dom/ecmascript/spidermonkey/DOMLocator.h
Normal file
10
src/document/dom/ecmascript/spidermonkey/DOMLocator.h
Normal file
@ -0,0 +1,10 @@
|
||||
#ifndef EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_DOMLOCATOR_H
|
||||
#define EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_DOMLOCATOR_H
|
||||
|
||||
#include "ecmascript/spidermonkey/util.h"
|
||||
|
||||
extern const JSClass DOMLocator_class;
|
||||
extern const JSPropertySpec DOMLocator_props[];
|
||||
|
||||
#endif
|
||||
|
58
src/document/dom/ecmascript/spidermonkey/DOMStringList.c
Normal file
58
src/document/dom/ecmascript/spidermonkey/DOMStringList.c
Normal file
@ -0,0 +1,58 @@
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include "elinks.h"
|
||||
#include "document/dom/ecmascript/spidermonkey.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/DOMStringList.h"
|
||||
|
||||
static JSBool
|
||||
DOMStringList_getProperty(JSContext *ctx, JSObject *obj, jsval id, jsval *vp)
|
||||
{
|
||||
if (!JSVAL_IS_INT(id))
|
||||
return JS_TRUE;
|
||||
switch (JSVAL_TO_INT(id)) {
|
||||
case JSP_DOM_LENGTH:
|
||||
/* Write me! */
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
DOMStringList_item(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
DOMStringList_contains(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
const JSPropertySpec DOMStringList_props[] = {
|
||||
{ "length", JSP_DOM_LENGTH, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ NULL }
|
||||
};
|
||||
|
||||
const JSFunctionSpec DOMStringList_funcs[] = {
|
||||
{ "item", DOMStringList_item, 1 },
|
||||
{ "contains", DOMStringList_contains, 1 },
|
||||
{ NULL }
|
||||
};
|
||||
|
||||
const JSClass DOMStringList_class = {
|
||||
"DOMStringList",
|
||||
JSCLASS_HAS_PRIVATE,
|
||||
JS_PropertyStub, JS_PropertyStub,
|
||||
DOMStringList_getProperty, JS_PropertyStub,
|
||||
JS_EnumerateStub, JS_ResolveStub, JS_ConvertStub, JS_FinalizeStub
|
||||
};
|
||||
|
11
src/document/dom/ecmascript/spidermonkey/DOMStringList.h
Normal file
11
src/document/dom/ecmascript/spidermonkey/DOMStringList.h
Normal file
@ -0,0 +1,11 @@
|
||||
#ifndef EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_DOMSTRINGLIST_H
|
||||
#define EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_DOMSTRINGLIST_H
|
||||
|
||||
#include "ecmascript/spidermonkey/util.h"
|
||||
|
||||
extern const JSClass DOMStringList_class;
|
||||
extern const JSFunctionSpec DOMStringList_funcs[];
|
||||
extern const JSPropertySpec DOMStringList_props[];
|
||||
|
||||
#endif
|
||||
|
254
src/document/dom/ecmascript/spidermonkey/Document.c
Normal file
254
src/document/dom/ecmascript/spidermonkey/Document.c
Normal file
@ -0,0 +1,254 @@
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include "elinks.h"
|
||||
#include "document/dom/ecmascript/spidermonkey.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/Document.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/Node.h"
|
||||
|
||||
static JSBool
|
||||
Document_getProperty(JSContext *ctx, JSObject *obj, jsval id, jsval *vp)
|
||||
{
|
||||
if (!JSVAL_IS_INT(id))
|
||||
return JS_TRUE;
|
||||
switch (JSVAL_TO_INT(id)) {
|
||||
case JSP_DOM_DOCTYPE:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_IMPLEMENTATION:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_DOCUMENT_ELEMENT:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_INPUT_ENCODING:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_XML_ENCODING:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_XML_STANDALONE:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_XML_VERSION:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_STRICT_ERROR_CHECKING:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_DOCUMENT_URI:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_DOM_CONFIG:
|
||||
/* Write me! */
|
||||
break;
|
||||
default:
|
||||
return Node_getProperty(ctx, obj, id, vp);
|
||||
}
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Document_setProperty(JSContext *ctx, JSObject *obj, jsval id, jsval *vp)
|
||||
{
|
||||
if (!JSVAL_IS_INT(id))
|
||||
return JS_TRUE;
|
||||
switch (JSVAL_TO_INT(id)) {
|
||||
case JSP_DOM_XML_STANDALONE:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_XML_VERSION:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_STRICT_ERROR_CHECKING:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_DOCUMENT_URI:
|
||||
/* Write me! */
|
||||
break;
|
||||
default:
|
||||
return Node_setProperty(ctx, obj, id, vp);
|
||||
}
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Document_createElement(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Document_createDocumentFragment(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Document_createTextNode(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Document_createComment(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Document_createCDATASection(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Document_createProcessingInstruction(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Document_createAttribute(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Document_createEntityReference(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Document_getElementsByTagName(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Document_importNode(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Document_createElementNS(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Document_createAttributeNS(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Document_getElementsByTagNameNS(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Document_getElementById(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Document_adoptNode(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Document_normalizeDocument(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Document_renameNode(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
const JSPropertySpec Document_props[] = {
|
||||
{ "doctype", JSP_DOM_DOCTYPE, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "implementation", JSP_DOM_IMPLEMENTATION, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "documentElement", JSP_DOM_DOCUMENT_ELEMENT, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "inputEncoding", JSP_DOM_INPUT_ENCODING, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "xmlEncoding", JSP_DOM_XML_ENCODING, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "xmlStandalone", JSP_DOM_XML_STANDALONE, JSPROP_ENUMERATE },
|
||||
{ "xmlVersion", JSP_DOM_XML_VERSION, JSPROP_ENUMERATE },
|
||||
{ "strictErrorChecking",JSP_DOM_STRICT_ERROR_CHECKING, JSPROP_ENUMERATE },
|
||||
{ "documentURI", JSP_DOM_DOCUMENT_URI, JSPROP_ENUMERATE },
|
||||
{ "domConfig", JSP_DOM_DOM_CONFIG, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ NULL }
|
||||
};
|
||||
|
||||
const JSFunctionSpec Document_funcs[] = {
|
||||
{ "createElement", Document_createElement, 1 },
|
||||
{ "createDocumentFragment", Document_createDocumentFragment, 0 },
|
||||
{ "createTextNode", Document_createTextNode, 1 },
|
||||
{ "createComment", Document_createComment, 1 },
|
||||
{ "createCDATASection", Document_createCDATASection, 1 },
|
||||
{ "createProcessingInstruction",Document_createProcessingInstruction, 2 },
|
||||
{ "createAttribute", Document_createAttribute, 1 },
|
||||
{ "createEntityReference", Document_createEntityReference, 1 },
|
||||
{ "getElementsByTagName", Document_getElementsByTagName, 1 },
|
||||
{ "importNode", Document_importNode, 2 },
|
||||
{ "createElementNS", Document_createElementNS, 2 },
|
||||
{ "createAttributeNS", Document_createAttributeNS, 2 },
|
||||
{ "getElementsByTagNameNS", Document_getElementsByTagNameNS, 2 },
|
||||
{ "getElementById", Document_getElementById, 1 },
|
||||
{ "adoptNode", Document_adoptNode, 1 },
|
||||
{ "normalizeDocument", Document_normalizeDocument, 0 },
|
||||
{ "renameNode", Document_renameNode, 3 },
|
||||
{ NULL }
|
||||
};
|
||||
|
||||
const JSClass Document_class = {
|
||||
"Document",
|
||||
JSCLASS_HAS_PRIVATE,
|
||||
JS_PropertyStub, JS_PropertyStub,
|
||||
Document_getProperty, Document_setProperty,
|
||||
JS_EnumerateStub, JS_ResolveStub, JS_ConvertStub, JS_FinalizeStub
|
||||
};
|
||||
|
11
src/document/dom/ecmascript/spidermonkey/Document.h
Normal file
11
src/document/dom/ecmascript/spidermonkey/Document.h
Normal file
@ -0,0 +1,11 @@
|
||||
#ifndef EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_DOCUMENT_H
|
||||
#define EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_DOCUMENT_H
|
||||
|
||||
#include "ecmascript/spidermonkey/util.h"
|
||||
|
||||
extern const JSClass Document_class;
|
||||
extern const JSFunctionSpec Document_funcs[];
|
||||
extern const JSPropertySpec Document_props[];
|
||||
|
||||
#endif
|
||||
|
17
src/document/dom/ecmascript/spidermonkey/DocumentFragment.c
Normal file
17
src/document/dom/ecmascript/spidermonkey/DocumentFragment.c
Normal file
@ -0,0 +1,17 @@
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include "elinks.h"
|
||||
#include "document/dom/ecmascript/spidermonkey.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/DocumentFragment.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/Node.h"
|
||||
|
||||
const JSClass DocumentFragment_class = {
|
||||
"DocumentFragment",
|
||||
JSCLASS_HAS_PRIVATE,
|
||||
JS_PropertyStub, JS_PropertyStub,
|
||||
Node_getProperty, Node_setProperty,
|
||||
JS_EnumerateStub, JS_ResolveStub, JS_ConvertStub, JS_FinalizeStub
|
||||
};
|
||||
|
@ -0,0 +1,9 @@
|
||||
#ifndef EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_DOCUMENTFRAGMENT_H
|
||||
#define EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_DOCUMENTFRAGMENT_H
|
||||
|
||||
#include "ecmascript/spidermonkey/util.h"
|
||||
|
||||
extern const JSClass DocumentFragment_class;
|
||||
|
||||
#endif
|
||||
|
58
src/document/dom/ecmascript/spidermonkey/DocumentType.c
Normal file
58
src/document/dom/ecmascript/spidermonkey/DocumentType.c
Normal file
@ -0,0 +1,58 @@
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include "elinks.h"
|
||||
|
||||
#include "document/dom/ecmascript/spidermonkey.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/DocumentType.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/Node.h"
|
||||
|
||||
static JSBool
|
||||
DocumentType_getProperty(JSContext *ctx, JSObject *obj, jsval id, jsval *vp)
|
||||
{
|
||||
if (!JSVAL_IS_INT(id))
|
||||
return JS_TRUE;
|
||||
switch (JSVAL_TO_INT(id)) {
|
||||
case JSP_DOM_NAME:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_ENTITIES:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_NOTATIONS:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_PUBLIC_ID:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_SYSTEM_ID:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_INTERNAL_SUBSET:
|
||||
/* Write me! */
|
||||
break;
|
||||
default:
|
||||
return Node_getProperty(ctx, obj, id, vp);
|
||||
}
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
const JSPropertySpec DocumentType_props[] = {
|
||||
{ "name", JSP_DOM_NAME, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "entities", JSP_DOM_ENTITIES, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "notations", JSP_DOM_NOTATIONS, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "publicId", JSP_DOM_PUBLIC_ID, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "systemId", JSP_DOM_SYSTEM_ID, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "internalSubset", JSP_DOM_INTERNAL_SUBSET,JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ NULL }
|
||||
};
|
||||
|
||||
const JSClass DocumentType_class = {
|
||||
"DocumentType",
|
||||
JSCLASS_HAS_PRIVATE,
|
||||
JS_PropertyStub, JS_PropertyStub,
|
||||
DocumentType_getProperty, Node_setProperty,
|
||||
JS_EnumerateStub, JS_ResolveStub, JS_ConvertStub, JS_FinalizeStub
|
||||
};
|
||||
|
10
src/document/dom/ecmascript/spidermonkey/DocumentType.h
Normal file
10
src/document/dom/ecmascript/spidermonkey/DocumentType.h
Normal file
@ -0,0 +1,10 @@
|
||||
#ifndef EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_DOCUMENTTYPE_H
|
||||
#define EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_DOCUMENTTYPE_H
|
||||
|
||||
#include "ecmascript/spidermonkey/util.h"
|
||||
|
||||
extern const JSClass DocumentType_class;
|
||||
extern const JSPropertySpec DocumentType_props[];
|
||||
|
||||
#endif
|
||||
|
207
src/document/dom/ecmascript/spidermonkey/Element.c
Normal file
207
src/document/dom/ecmascript/spidermonkey/Element.c
Normal file
@ -0,0 +1,207 @@
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include "elinks.h"
|
||||
|
||||
#include "document/dom/ecmascript/spidermonkey.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/Element.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/Node.h"
|
||||
|
||||
static JSBool
|
||||
Element_getProperty(JSContext *ctx, JSObject *obj, jsval id, jsval *vp)
|
||||
{
|
||||
if (!JSVAL_IS_INT(id))
|
||||
return JS_TRUE;
|
||||
switch (JSVAL_TO_INT(id)) {
|
||||
case JSP_DOM_TAG_NAME:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_SCHEMA_TYPE_INFO:
|
||||
/* Write me! */
|
||||
break;
|
||||
default:
|
||||
return Node_getProperty(ctx, obj, id, vp);
|
||||
}
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Element_getAttribute(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Element_setAttribute(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Element_removeAttribute(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Element_getAttributeNode(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Element_setAttributeNode(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Element_removeAttributeNode(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Element_getElementsByTagName(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Element_getAttributeNS(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Element_setAttributeNS(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Element_removeAttributeNS(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
static JSBool
|
||||
Element_getAttributeNodeNS(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Element_setAttributeNodeNS(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Element_getElementsByTagNameNS(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Element_hasAttribute(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Element_hasAttributeNS(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Element_setIdAttribute(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Element_setIdAttributeNS(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Element_setIdAttributeNode(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
const JSPropertySpec Element_props[] = {
|
||||
{ "tagName", JSP_DOM_TAG_NAME, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "schemaTypeInfo", JSP_DOM_SCHEMA_TYPE_INFO, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ NULL }
|
||||
};
|
||||
|
||||
const JSFunctionSpec Element_funcs[] = {
|
||||
{ "getAttribute", Element_getAttribute, 1 },
|
||||
{ "setAttribute", Element_setAttribute, 2 },
|
||||
{ "removeAttribute", Element_removeAttribute, 1 },
|
||||
{ "getAttributeNode", Element_getAttributeNode, 1 },
|
||||
{ "setAttributeNode", Element_setAttributeNode, 1 },
|
||||
{ "removeAttributeNode", Element_removeAttributeNode, 1 },
|
||||
{ "getElementsByTagName", Element_getElementsByTagName, 1 },
|
||||
{ "getAttributeNS", Element_getAttributeNS, 2 },
|
||||
{ "setAttributeNS", Element_setAttributeNS, 3 },
|
||||
{ "removeAttributeNS", Element_removeAttributeNS, 2 },
|
||||
{ "getAttributeNodeNS", Element_getAttributeNodeNS, 2 },
|
||||
{ "setAttributeNodeNS", Element_setAttributeNodeNS, 1 },
|
||||
{ "getElementsByTagNameNS", Element_getElementsByTagNameNS, 2 },
|
||||
{ "hasAttribute", Element_hasAttribute, 1 },
|
||||
{ "hasAttributeNS", Element_hasAttributeNS, 2 },
|
||||
{ "setIdAttribute", Element_setIdAttribute, 2 },
|
||||
{ "setIdAttributeNS", Element_setIdAttributeNS, 3 },
|
||||
{ "setIdAttributeNode", Element_setIdAttributeNode, 2 },
|
||||
{ NULL }
|
||||
};
|
||||
|
||||
const JSClass Element_class = {
|
||||
"Element",
|
||||
JSCLASS_HAS_PRIVATE,
|
||||
JS_PropertyStub, JS_PropertyStub,
|
||||
Element_getProperty, Node_setProperty,
|
||||
JS_EnumerateStub, JS_ResolveStub, JS_ConvertStub, JS_FinalizeStub
|
||||
};
|
||||
|
11
src/document/dom/ecmascript/spidermonkey/Element.h
Normal file
11
src/document/dom/ecmascript/spidermonkey/Element.h
Normal file
@ -0,0 +1,11 @@
|
||||
#ifndef EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_ELEMENT_H
|
||||
#define EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_ELEMENT_H
|
||||
|
||||
#include "ecmascript/spidermonkey/util.h"
|
||||
|
||||
extern const JSClass Element_class;
|
||||
extern const JSFunctionSpec Element_funcs[];
|
||||
extern const JSPropertySpec Element_props[];
|
||||
|
||||
#endif
|
||||
|
57
src/document/dom/ecmascript/spidermonkey/Entity.c
Normal file
57
src/document/dom/ecmascript/spidermonkey/Entity.c
Normal file
@ -0,0 +1,57 @@
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include "elinks.h"
|
||||
#include "document/dom/ecmascript/spidermonkey.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/Entity.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/Node.h"
|
||||
|
||||
static JSBool
|
||||
Entity_getProperty(JSContext *ctx, JSObject *obj, jsval id, jsval *vp)
|
||||
{
|
||||
if (!JSVAL_IS_INT(id))
|
||||
return JS_TRUE;
|
||||
switch (JSVAL_TO_INT(id)) {
|
||||
case JSP_DOM_PUBLIC_ID:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_SYSTEM_ID:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_NOTATION_NAME:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_INPUT_ENCODING:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_XML_ENCODING:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_XML_VERSION:
|
||||
/* Write me! */
|
||||
break;
|
||||
default:
|
||||
return Node_getProperty(ctx, obj, id, vp);
|
||||
}
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
const JSPropertySpec Entity_props[] = {
|
||||
{ "publicId", JSP_DOM_PUBLIC_ID, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "systemId", JSP_DOM_SYSTEM_ID, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "notationName", JSP_DOM_NOTATION_NAME, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "inputEncoding", JSP_DOM_INPUT_ENCODING, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "xmlEncoding", JSP_DOM_XML_ENCODING, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "xmlVersion", JSP_DOM_XML_VERSION, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ NULL }
|
||||
};
|
||||
|
||||
const JSClass Entity_class = {
|
||||
"Entity",
|
||||
JSCLASS_HAS_PRIVATE,
|
||||
JS_PropertyStub, JS_PropertyStub,
|
||||
Entity_getProperty, Node_setProperty,
|
||||
JS_EnumerateStub, JS_ResolveStub, JS_ConvertStub, JS_FinalizeStub
|
||||
};
|
||||
|
10
src/document/dom/ecmascript/spidermonkey/Entity.h
Normal file
10
src/document/dom/ecmascript/spidermonkey/Entity.h
Normal file
@ -0,0 +1,10 @@
|
||||
#ifndef EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_ENTITY_H
|
||||
#define EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_ENTITY_H
|
||||
|
||||
#include "ecmascript/spidermonkey/util.h"
|
||||
|
||||
extern const JSClass Entity_class;
|
||||
extern const JSPropertySpec Entity_props[];
|
||||
|
||||
#endif
|
||||
|
17
src/document/dom/ecmascript/spidermonkey/EntityReference.c
Normal file
17
src/document/dom/ecmascript/spidermonkey/EntityReference.c
Normal file
@ -0,0 +1,17 @@
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include "elinks.h"
|
||||
#include "document/dom/ecmascript/spidermonkey.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/EntityReference.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/Node.h"
|
||||
|
||||
const JSClass EntityReference_class = {
|
||||
"EntityReference",
|
||||
JSCLASS_HAS_PRIVATE,
|
||||
JS_PropertyStub, JS_PropertyStub,
|
||||
Node_getProperty, Node_setProperty,
|
||||
JS_EnumerateStub, JS_ResolveStub, JS_ConvertStub, JS_FinalizeStub
|
||||
};
|
||||
|
@ -0,0 +1,9 @@
|
||||
#ifndef EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_ENTITYREFERENCE_H
|
||||
#define EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_ENTITYREFERENCE_H
|
||||
|
||||
#include "ecmascript/spidermonkey/util.h"
|
||||
|
||||
extern const JSClass EntityReference_class;
|
||||
|
||||
#endif
|
||||
|
15
src/document/dom/ecmascript/spidermonkey/Makefile
Normal file
15
src/document/dom/ecmascript/spidermonkey/Makefile
Normal file
@ -0,0 +1,15 @@
|
||||
top_builddir=../../../../..
|
||||
include $(top_builddir)/Makefile.config
|
||||
|
||||
INCLUDES += $(SPIDERMONKEY_CFLAGS)
|
||||
OBJS = Attr.o CDATASection.o CharacterData.o Comment.o Document.o \
|
||||
DocumentFragment.o DocumentType.o DOMConfiguration.o \
|
||||
DOMError.o DOMErrorHandler.o DOMException.o \
|
||||
DOMImplementation.o DOMImplementationList.o \
|
||||
DOMImplementationRegistry.o DOMImplementationSource.o \
|
||||
DOMLocator.o DOMStringList.o Element.o Entity.o \
|
||||
EntityReference.o NamedNodeMap.o NameList.o \
|
||||
Node.o NodeList.o Notation.o ProcessingInstruction.o \
|
||||
Text.o TypeInfo.o UserDataHandler.o
|
||||
|
||||
include $(top_srcdir)/Makefile.lib
|
77
src/document/dom/ecmascript/spidermonkey/NameList.c
Normal file
77
src/document/dom/ecmascript/spidermonkey/NameList.c
Normal file
@ -0,0 +1,77 @@
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include "elinks.h"
|
||||
|
||||
#include "document/dom/ecmascript/spidermonkey.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/NameList.h"
|
||||
|
||||
static JSBool
|
||||
NameList_getProperty(JSContext *ctx, JSObject *obj, jsval id, jsval *vp)
|
||||
{
|
||||
if (!JSVAL_IS_INT(id))
|
||||
return JS_TRUE;
|
||||
switch (JSVAL_TO_INT(id)) {
|
||||
case JSP_DOM_LENGTH:
|
||||
/* Write me! */
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
NameList_getName(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
NameList_getNamespaceURI(JSContext *ctx, JSObject *obj, uintN argc,
|
||||
jsval *argv, jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
NameList_contains(JSContext *ctx, JSObject *obj, uintN argc,
|
||||
jsval *argv, jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
NameList_containsNS(JSContext *ctx, JSObject *obj, uintN argc,
|
||||
jsval *argv, jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
const JSPropertySpec NameList_props[] = {
|
||||
{ "length", JSP_DOM_LENGTH, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ NULL }
|
||||
};
|
||||
|
||||
const JSFunctionSpec NameList_funcs[] = {
|
||||
{ "getName", NameList_getName, 1 },
|
||||
{ "getNamespaceURI", NameList_getNamespaceURI, 1 },
|
||||
{ "contains", NameList_contains, 1 },
|
||||
{ "containsNS", NameList_containsNS, 2 },
|
||||
{ NULL }
|
||||
};
|
||||
|
||||
const JSClass NameList_class = {
|
||||
"NameList",
|
||||
JSCLASS_HAS_PRIVATE,
|
||||
JS_PropertyStub, JS_PropertyStub,
|
||||
NameList_getProperty, JS_PropertyStub,
|
||||
JS_EnumerateStub, JS_ResolveStub, JS_ConvertStub, JS_FinalizeStub
|
||||
};
|
||||
|
11
src/document/dom/ecmascript/spidermonkey/NameList.h
Normal file
11
src/document/dom/ecmascript/spidermonkey/NameList.h
Normal file
@ -0,0 +1,11 @@
|
||||
#ifndef EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_NAMELIST_H
|
||||
#define EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_NAMELIST_H
|
||||
|
||||
#include "ecmascript/spidermonkey/util.h"
|
||||
|
||||
extern const JSClass NameList_class;
|
||||
extern const JSFunctionSpec NameList_funcs[];
|
||||
extern const JSPropertySpec NameList_props[];
|
||||
|
||||
#endif
|
||||
|
103
src/document/dom/ecmascript/spidermonkey/NamedNodeMap.c
Normal file
103
src/document/dom/ecmascript/spidermonkey/NamedNodeMap.c
Normal file
@ -0,0 +1,103 @@
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include "elinks.h"
|
||||
#include "document/dom/ecmascript/spidermonkey.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/NamedNodeMap.h"
|
||||
|
||||
static JSBool
|
||||
NamedNodeMap_getProperty(JSContext *ctx, JSObject *obj, jsval id, jsval *vp)
|
||||
{
|
||||
if (!JSVAL_IS_INT(id))
|
||||
return JS_TRUE;
|
||||
switch (JSVAL_TO_INT(id)) {
|
||||
case JSP_DOM_LENGTH:
|
||||
/* Write me! */
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
NamedNodeMap_getNamedItem(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
NamedNodeMap_setNamedItem(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
NamedNodeMap_removeNamedItem(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
NamedNodeMap_item(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
NamedNodeMap_getNamedItemNS(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
NamedNodeMap_setNamedItemNS(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
NamedNodeMap_removeNamedItemNS(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
const JSPropertySpec NamedNodeMap_props[] = {
|
||||
{ "length", JSP_DOM_LENGTH, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ NULL }
|
||||
};
|
||||
|
||||
const JSFunctionSpec NamedNodeMap_funcs[] = {
|
||||
{ "getNamedItem", NamedNodeMap_getNamedItem, 1 },
|
||||
{ "setNamedItem", NamedNodeMap_setNamedItem, 1 },
|
||||
{ "removeNamedItem", NamedNodeMap_removeNamedItem, 1 },
|
||||
{ "item", NamedNodeMap_item, 1 },
|
||||
{ "getNamedItemNS", NamedNodeMap_getNamedItemNS, 2 },
|
||||
{ "setNamedItemNS", NamedNodeMap_setNamedItemNS, 1 },
|
||||
{ "removeNamedItemNS", NamedNodeMap_removeNamedItemNS, 2 },
|
||||
{ NULL }
|
||||
};
|
||||
|
||||
const JSClass NamedNodeMap_class = {
|
||||
"NamedNodeMap",
|
||||
JSCLASS_HAS_PRIVATE,
|
||||
JS_PropertyStub, JS_PropertyStub,
|
||||
NamedNodeMap_getProperty, JS_PropertyStub,
|
||||
JS_EnumerateStub, JS_ResolveStub, JS_ConvertStub, JS_FinalizeStub
|
||||
};
|
||||
|
11
src/document/dom/ecmascript/spidermonkey/NamedNodeMap.h
Normal file
11
src/document/dom/ecmascript/spidermonkey/NamedNodeMap.h
Normal file
@ -0,0 +1,11 @@
|
||||
#ifndef EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_NAMEDNODEMAP_H
|
||||
#define EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_NAMEDNODEMAP_H
|
||||
|
||||
#include "ecmascript/spidermonkey/util.h"
|
||||
|
||||
extern const JSClass NamedNodeMap_class;
|
||||
extern const JSFunctionSpec NamedNodeMap_funcs[];
|
||||
extern const JSPropertySpec NamedNodeMap_props[];
|
||||
|
||||
#endif
|
||||
|
283
src/document/dom/ecmascript/spidermonkey/Node.c
Normal file
283
src/document/dom/ecmascript/spidermonkey/Node.c
Normal file
@ -0,0 +1,283 @@
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include "elinks.h"
|
||||
#include "document/dom/ecmascript/spidermonkey.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/Node.h"
|
||||
|
||||
JSBool
|
||||
Node_getProperty(JSContext *ctx, JSObject *obj, jsval id, jsval *vp)
|
||||
{
|
||||
if (!JSVAL_IS_INT(id))
|
||||
return JS_TRUE;
|
||||
switch (JSVAL_TO_INT(id)) {
|
||||
case JSP_DOM_NODE_NAME:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_NODE_VALUE:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_NODE_TYPE:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_PARENT_NODE:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_CHILD_NODES:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_FIRST_CHILD:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_LAST_CHILD:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_PREVIOUS_SIBLING:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_NEXT_SIBLING:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_ATTRIBUTES:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_OWNER_DOCUMENT:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_NAMESPACE_URI:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_PREFIX:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_LOCAL_NAME:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_BASE_URI:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_TEXT_CONTENT:
|
||||
/* Write me! */
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
JSBool
|
||||
Node_setProperty(JSContext *ctx, JSObject *obj, jsval id, jsval *vp)
|
||||
{
|
||||
if (!JSVAL_IS_INT(id))
|
||||
return JS_TRUE;
|
||||
switch (JSVAL_TO_INT(id)) {
|
||||
case JSP_DOM_NODE_VALUE:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_PREFIX:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_TEXT_CONTENT:
|
||||
/* Write me! */
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Node_insertBefore(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Node_replaceChild(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Node_removeChild(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Node_appendChild(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Node_hasChildNodes(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Node_cloneNode(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Node_normalize(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Node_isSupported(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Node_hasAttributes(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Node_compareDocumentPosition(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Node_isSameNode(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Node_lookupPrefix(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Node_isDefaultNamespace(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Node_lookupNamespaceURI(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Node_isEqualNode(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Node_getFeature(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Node_setUserData(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Node_getUserData(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
const JSPropertySpec Node_props[] = {
|
||||
{ "nodeName", JSP_DOM_NODE_NAME, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "nodeValue", JSP_DOM_NODE_VALUE, JSPROP_ENUMERATE },
|
||||
{ "nodeType", JSP_DOM_NODE_TYPE, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "parentNode", JSP_DOM_PARENT_NODE, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "childNodes", JSP_DOM_CHILD_NODES, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "firstChild", JSP_DOM_FIRST_CHILD, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "lastChild", JSP_DOM_LAST_CHILD, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "previousSibling", JSP_DOM_PREVIOUS_SIBLING, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "nextSibling", JSP_DOM_NEXT_SIBLING, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "attributes", JSP_DOM_ATTRIBUTES, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "ownerDocument", JSP_DOM_OWNER_DOCUMENT, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "namespaceURI", JSP_DOM_NAMESPACE_URI, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "prefix" , JSP_DOM_PREFIX, JSPROP_ENUMERATE },
|
||||
{ "localName", JSP_DOM_LOCAL_NAME, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "baseURI", JSP_DOM_BASE_URI, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "textContent", JSP_DOM_TEXT_CONTENT, JSPROP_ENUMERATE },
|
||||
{ NULL }
|
||||
};
|
||||
|
||||
const JSFunctionSpec Node_funcs[] = {
|
||||
{ "insertBefore", Node_insertBefore, 2 },
|
||||
{ "replaceChild", Node_replaceChild, 2 },
|
||||
{ "removeChild", Node_removeChild, 1 },
|
||||
{ "appendChild", Node_appendChild, 1 },
|
||||
{ "hasChildNodes", Node_hasChildNodes, 0 },
|
||||
{ "cloneNode", Node_cloneNode, 1 },
|
||||
{ "normalize", Node_normalize, 0 },
|
||||
{ "isSupported", Node_isSupported, 2 },
|
||||
{ "hasAttributes", Node_hasAttributes, 0 },
|
||||
{ "compareDocumentPosition", Node_compareDocumentPosition, 1 },
|
||||
{ "isSameNode", Node_isSameNode, 1 },
|
||||
{ "lookupPrefix", Node_lookupPrefix, 1 },
|
||||
{ "isDefaultNamespace", Node_isDefaultNamespace, 1 },
|
||||
{ "lookupNamespaceURI", Node_lookupNamespaceURI, 1 },
|
||||
{ "isEqualNode", Node_isEqualNode, 1 },
|
||||
{ "getFeature", Node_getFeature, 2 },
|
||||
{ "setUserData", Node_setUserData, 3 },
|
||||
{ "getUserData", Node_getUserData, 1 },
|
||||
{ NULL }
|
||||
};
|
||||
|
||||
const JSClass Node_class = {
|
||||
"Node",
|
||||
JSCLASS_HAS_PRIVATE,
|
||||
JS_PropertyStub, JS_PropertyStub,
|
||||
Node_getProperty, Node_setProperty,
|
||||
JS_EnumerateStub, JS_ResolveStub, JS_ConvertStub, JS_FinalizeStub
|
||||
};
|
||||
|
14
src/document/dom/ecmascript/spidermonkey/Node.h
Normal file
14
src/document/dom/ecmascript/spidermonkey/Node.h
Normal file
@ -0,0 +1,14 @@
|
||||
#ifndef EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_NODE_H
|
||||
#define EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_NODE_H
|
||||
|
||||
#include "ecmascript/spidermonkey/util.h"
|
||||
|
||||
extern const JSClass Node_class;
|
||||
extern const JSFunctionSpec Node_funcs[];
|
||||
extern const JSPropertySpec Node_props[];
|
||||
|
||||
JSBool Node_getProperty(JSContext *ctx, JSObject *obj, jsval id, jsval *vp);
|
||||
JSBool Node_setProperty(JSContext *ctx, JSObject *obj, jsval id, jsval *vp);
|
||||
|
||||
#endif
|
||||
|
49
src/document/dom/ecmascript/spidermonkey/NodeList.c
Normal file
49
src/document/dom/ecmascript/spidermonkey/NodeList.c
Normal file
@ -0,0 +1,49 @@
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include "elinks.h"
|
||||
|
||||
#include "document/dom/ecmascript/spidermonkey.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/NodeList.h"
|
||||
|
||||
static JSBool
|
||||
NodeList_getProperty(JSContext *ctx, JSObject *obj, jsval id, jsval *vp)
|
||||
{
|
||||
if (!JSVAL_IS_INT(id))
|
||||
return JS_TRUE;
|
||||
switch (JSVAL_TO_INT(id)) {
|
||||
case JSP_DOM_LENGTH:
|
||||
/* Write me! */
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
NodeList_item(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv, jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
const JSPropertySpec NodeList_props[] = {
|
||||
{ "length", JSP_DOM_LENGTH, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ NULL }
|
||||
};
|
||||
|
||||
const JSFunctionSpec NodeList_funcs[] = {
|
||||
{ "item", NodeList_item, 1 },
|
||||
{ NULL }
|
||||
};
|
||||
|
||||
const JSClass NodeList_class = {
|
||||
"NodeList",
|
||||
JSCLASS_HAS_PRIVATE,
|
||||
JS_PropertyStub, JS_PropertyStub,
|
||||
NodeList_getProperty, JS_PropertyStub,
|
||||
JS_EnumerateStub, JS_ResolveStub, JS_ConvertStub, JS_FinalizeStub
|
||||
};
|
||||
|
11
src/document/dom/ecmascript/spidermonkey/NodeList.h
Normal file
11
src/document/dom/ecmascript/spidermonkey/NodeList.h
Normal file
@ -0,0 +1,11 @@
|
||||
#ifndef EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_NODELIST_H
|
||||
#define EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_NODELIST_H
|
||||
|
||||
#include "ecmascript/spidermonkey/util.h"
|
||||
|
||||
extern const JSClass NodeList_class;
|
||||
extern const JSFunctionSpec NodeList_funcs[];
|
||||
extern const JSPropertySpec NodeList_props[];
|
||||
|
||||
#endif
|
||||
|
42
src/document/dom/ecmascript/spidermonkey/Notation.c
Normal file
42
src/document/dom/ecmascript/spidermonkey/Notation.c
Normal file
@ -0,0 +1,42 @@
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include "elinks.h"
|
||||
|
||||
#include "document/dom/ecmascript/spidermonkey.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/Node.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/Notation.h"
|
||||
|
||||
static JSBool
|
||||
Notation_getProperty(JSContext *ctx, JSObject *obj, jsval id, jsval *vp)
|
||||
{
|
||||
if (!JSVAL_IS_INT(id))
|
||||
return JS_TRUE;
|
||||
switch (JSVAL_TO_INT(id)) {
|
||||
case JSP_DOM_PUBLIC_ID:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_SYSTEM_ID:
|
||||
/* Write me! */
|
||||
break;
|
||||
default:
|
||||
return Node_getProperty(ctx, obj, id, vp);
|
||||
}
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
const JSPropertySpec Notation_props[] = {
|
||||
{ "publicId", JSP_DOM_PUBLIC_ID, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "systemId", JSP_DOM_SYSTEM_ID, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ NULL }
|
||||
};
|
||||
|
||||
const JSClass Notation_class = {
|
||||
"Notation",
|
||||
JSCLASS_HAS_PRIVATE,
|
||||
JS_PropertyStub, JS_PropertyStub,
|
||||
Notation_getProperty, Node_setProperty,
|
||||
JS_EnumerateStub, JS_ResolveStub, JS_ConvertStub, JS_FinalizeStub
|
||||
};
|
||||
|
10
src/document/dom/ecmascript/spidermonkey/Notation.h
Normal file
10
src/document/dom/ecmascript/spidermonkey/Notation.h
Normal file
@ -0,0 +1,10 @@
|
||||
#ifndef EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_NOTATION_H
|
||||
#define EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_NOTATION_H
|
||||
|
||||
#include "ecmascript/spidermonkey/util.h"
|
||||
|
||||
extern const JSClass Notation_class;
|
||||
extern const JSPropertySpec Notation_props[];
|
||||
|
||||
#endif
|
||||
|
@ -0,0 +1,59 @@
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include "elinks.h"
|
||||
|
||||
#include "document/dom/ecmascript/spidermonkey.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/Node.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/ProcessingInstruction.h"
|
||||
|
||||
static JSBool
|
||||
ProcessingInstruction_getProperty(JSContext *ctx, JSObject *obj, jsval id, jsval *vp)
|
||||
{
|
||||
if (!JSVAL_IS_INT(id))
|
||||
return JS_TRUE;
|
||||
|
||||
switch (JSVAL_TO_INT(id)) {
|
||||
case JSP_DOM_TARGET:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_DATA:
|
||||
/* Write me! */
|
||||
break;
|
||||
default:
|
||||
return Node_getProperty(ctx, obj, id, vp);
|
||||
}
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
ProcessingInstruction_setProperty(JSContext *ctx, JSObject *obj, jsval id, jsval *vp)
|
||||
{
|
||||
if (!JSVAL_IS_INT(id))
|
||||
return JS_TRUE;
|
||||
|
||||
switch (JSVAL_TO_INT(id)) {
|
||||
case JSP_DOM_DATA:
|
||||
/* Write me ! */
|
||||
break;
|
||||
default:
|
||||
return Node_setProperty(ctx, obj, id, vp);
|
||||
}
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
const JSPropertySpec ProcessingInstruction_props[] = {
|
||||
{ "data", JSP_DOM_DATA, JSPROP_ENUMERATE },
|
||||
{ "target", JSP_DOM_TARGET, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ NULL }
|
||||
};
|
||||
|
||||
const JSClass ProcessingInstruction_class = {
|
||||
"ProcessingInstruction",
|
||||
JSCLASS_HAS_PRIVATE,
|
||||
JS_PropertyStub, JS_PropertyStub,
|
||||
ProcessingInstruction_getProperty, ProcessingInstruction_setProperty,
|
||||
JS_EnumerateStub, JS_ResolveStub, JS_ConvertStub, JS_FinalizeStub
|
||||
};
|
||||
|
@ -0,0 +1,10 @@
|
||||
#ifndef EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_PROCESSINGINSTRUCTION_H
|
||||
#define EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_PROCESSINGINSTRUCTION_H
|
||||
|
||||
#include "ecmascript/spidermonkey/util.h"
|
||||
|
||||
extern const JSClass ProcessingInstruction_class;
|
||||
extern const JSPropertySpec ProcessingInstruction_props[];
|
||||
|
||||
#endif
|
||||
|
64
src/document/dom/ecmascript/spidermonkey/Text.c
Normal file
64
src/document/dom/ecmascript/spidermonkey/Text.c
Normal file
@ -0,0 +1,64 @@
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include "elinks.h"
|
||||
|
||||
#include "document/dom/ecmascript/spidermonkey.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/CharacterData.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/Text.h"
|
||||
|
||||
JSBool
|
||||
Text_getProperty(JSContext *ctx, JSObject *obj, jsval id, jsval *vp)
|
||||
{
|
||||
if (!JSVAL_IS_INT(id))
|
||||
return JS_TRUE;
|
||||
switch (JSVAL_TO_INT(id)) {
|
||||
case JSP_DOM_IS_ELEMENT_CONTENT_WHITESPACE:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_WHOLE_TEXT:
|
||||
/* Write me! */
|
||||
break;
|
||||
default:
|
||||
return CharacterData_getProperty(ctx, obj, id, vp);
|
||||
}
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Text_splitText(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv,
|
||||
jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
Text_replaceWholeText(JSContext *ctx, JSObject *obj, uintN argc,
|
||||
jsval *argv, jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
const JSPropertySpec Text_props[] = {
|
||||
{ "isElementContentWhitespace", JSP_DOM_IS_ELEMENT_CONTENT_WHITESPACE, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "wholeText", JSP_DOM_TYPE_NAMESPACE, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ NULL }
|
||||
};
|
||||
|
||||
const JSFunctionSpec Text_funcs[] = {
|
||||
{ "splitText", Text_splitText, 1 },
|
||||
{ "replaceWholeText", Text_replaceWholeText, 1 },
|
||||
{ NULL }
|
||||
};
|
||||
|
||||
const JSClass Text_class = {
|
||||
"Text",
|
||||
JSCLASS_HAS_PRIVATE,
|
||||
JS_PropertyStub, JS_PropertyStub,
|
||||
Text_getProperty, CharacterData_setProperty,
|
||||
JS_EnumerateStub, JS_ResolveStub, JS_ConvertStub, JS_FinalizeStub
|
||||
};
|
||||
|
13
src/document/dom/ecmascript/spidermonkey/Text.h
Normal file
13
src/document/dom/ecmascript/spidermonkey/Text.h
Normal file
@ -0,0 +1,13 @@
|
||||
#ifndef EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_TEXT_H
|
||||
#define EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_TEXT_H
|
||||
|
||||
#include "ecmascript/spidermonkey/util.h"
|
||||
|
||||
extern const JSClass Text_class;
|
||||
extern const JSFunctionSpec Text_funcs[];
|
||||
extern const JSPropertySpec Text_props[];
|
||||
|
||||
JSBool Text_getProperty(JSContext *ctx, JSObject *obj, jsval id, jsval *vp);
|
||||
|
||||
#endif
|
||||
|
56
src/document/dom/ecmascript/spidermonkey/TypeInfo.c
Normal file
56
src/document/dom/ecmascript/spidermonkey/TypeInfo.c
Normal file
@ -0,0 +1,56 @@
|
||||
/* SpiderMonkey's DOM TypeInfo implementation */
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include "elinks.h"
|
||||
|
||||
#include "document/dom/ecmascript/spidermonkey.h"
|
||||
#include "document/dom/ecmascript/spidermonkey/TypeInfo.h"
|
||||
|
||||
static JSBool
|
||||
TypeInfo_getProperty(JSContext *ctx, JSObject *obj, jsval id, jsval *vp)
|
||||
{
|
||||
if (!JSVAL_IS_INT(id))
|
||||
return JS_TRUE;
|
||||
switch (JSVAL_TO_INT(id)) {
|
||||
case JSP_DOM_TYPE_NAME:
|
||||
/* Write me! */
|
||||
break;
|
||||
case JSP_DOM_TYPE_NAMESPACE:
|
||||
/* Write me! */
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
TypeInfo_isDerivedFrom(JSContext *ctx, JSObject *obj, uintN argc,
|
||||
jsval *argv, jsval *rval)
|
||||
{
|
||||
/* Write me! */
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
const JSPropertySpec TypeInfo_props[] = {
|
||||
{ "typeName", JSP_DOM_TYPE_NAME, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ "typeNamespace", JSP_DOM_TYPE_NAMESPACE, JSPROP_ENUMERATE | JSPROP_READONLY },
|
||||
{ NULL }
|
||||
};
|
||||
|
||||
const JSFunctionSpec TypeInfo_funcs[] = {
|
||||
{ "isDerivedFrom", TypeInfo_isDerivedFrom, 3},
|
||||
{ NULL }
|
||||
};
|
||||
|
||||
const JSClass TypeInfo_class = {
|
||||
"TypeInfo",
|
||||
JSCLASS_HAS_PRIVATE,
|
||||
JS_PropertyStub, JS_PropertyStub,
|
||||
TypeInfo_getProperty, JS_PropertyStub,
|
||||
JS_EnumerateStub, JS_ResolveStub, JS_ConvertStub, JS_FinalizeStub
|
||||
};
|
||||
|
11
src/document/dom/ecmascript/spidermonkey/TypeInfo.h
Normal file
11
src/document/dom/ecmascript/spidermonkey/TypeInfo.h
Normal file
@ -0,0 +1,11 @@
|
||||
#ifndef EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_TYPEINFO_H
|
||||
#define EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_TYPEINFO_H
|
||||
|
||||
#include "ecmascript/spidermonkey/util.h"
|
||||
|
||||
extern const JSClass TypeInfo_class;
|
||||
extern const JSFunctionSpec TypeInfo_funcs[];
|
||||
extern const JSPropertySpec TypeInfo_props[];
|
||||
|
||||
#endif
|
||||
|
10
src/document/dom/ecmascript/spidermonkey/UserDataHandler.c
Normal file
10
src/document/dom/ecmascript/spidermonkey/UserDataHandler.c
Normal file
@ -0,0 +1,10 @@
|
||||
/* What is UserDataHandler ? */
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include "elinks.h"
|
||||
|
||||
#include "document/dom/ecmascript/spidermonkey/UserDataHandler.h"
|
||||
|
@ -0,0 +1,7 @@
|
||||
#ifndef EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_USERDATAHANDLER_H
|
||||
#define EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_USERDATAHANDLER_H
|
||||
|
||||
#include "ecmascript/spidermonkey/util.h"
|
||||
|
||||
#endif
|
||||
|
66
src/document/dom/ecmascript/spidermonkey/props.h
Normal file
66
src/document/dom/ecmascript/spidermonkey/props.h
Normal file
@ -0,0 +1,66 @@
|
||||
#ifndef EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_PROPS_H
|
||||
#define EL__DOCUMENT_DOM_ECMASCRIPT_SPIDERMONKEY_PROPS_H
|
||||
enum dom_props {
|
||||
JSP_DOM_ATTRIBUTES = -120,
|
||||
JSP_DOM_BASE_URI,
|
||||
JSP_DOM_BYTE_OFFSET,
|
||||
JSP_DOM_CHILD_NODES,
|
||||
JSP_DOM_CODE,
|
||||
JSP_DOM_COLUMN_NUMBER,
|
||||
JSP_DOM_DATA,
|
||||
JSP_DOM_DOCTYPE,
|
||||
JSP_DOM_DOCUMENT_ELEMENT,
|
||||
JSP_DOM_DOCUMENT_URI,
|
||||
JSP_DOM_DOM_CONFIG,
|
||||
JSP_DOM_ENTITIES,
|
||||
JSP_DOM_FIRST_CHILD,
|
||||
JSP_DOM_IMPLEMENTATION,
|
||||
JSP_DOM_INPUT_ENCODING,
|
||||
JSP_DOM_INTERNAL_SUBSET,
|
||||
JSP_DOM_IS_ELEMENT_CONTENT_WHITESPACE,
|
||||
JSP_DOM_IS_ID,
|
||||
JSP_DOM_LAST_CHILD,
|
||||
JSP_DOM_LENGTH,
|
||||
JSP_DOM_LINE_NUMBER,
|
||||
JSP_DOM_LOCAL_NAME,
|
||||
JSP_DOM_LOCATION,
|
||||
JSP_DOM_MESSAGE,
|
||||
JSP_DOM_NAME,
|
||||
JSP_DOM_NAMESPACE_URI,
|
||||
JSP_DOM_NEXT_SIBLING,
|
||||
JSP_DOM_NODE_NAME,
|
||||
JSP_DOM_NODE_TYPE,
|
||||
JSP_DOM_NODE_VALUE,
|
||||
JSP_DOM_NOTATION_NAME,
|
||||
JSP_DOM_NOTATIONS,
|
||||
JSP_DOM_OWNER_DOCUMENT,
|
||||
JSP_DOM_OWNER_ELEMENT,
|
||||
JSP_DOM_PARAMETER_NAMES,
|
||||
JSP_DOM_PARENT_NODE,
|
||||
JSP_DOM_PREFIX,
|
||||
JSP_DOM_PREVIOUS_SIBLING,
|
||||
JSP_DOM_PUBLIC_ID,
|
||||
JSP_DOM_RELATED_DATA,
|
||||
JSP_DOM_RELATED_EXCEPTION,
|
||||
JSP_DOM_RELATED_NODE,
|
||||
JSP_DOM_SCHEMA_TYPE_INFO,
|
||||
JSP_DOM_SEVERITY,
|
||||
JSP_DOM_SPECIFIED,
|
||||
JSP_DOM_STRICT_ERROR_CHECKING,
|
||||
JSP_DOM_SYSTEM_ID,
|
||||
JSP_DOM_TAG_NAME,
|
||||
JSP_DOM_TARGET,
|
||||
JSP_DOM_TEXT_CONTENT,
|
||||
JSP_DOM_TYPE,
|
||||
JSP_DOM_TYPE_NAME,
|
||||
JSP_DOM_TYPE_NAMESPACE,
|
||||
JSP_DOM_URI,
|
||||
JSP_DOM_UTF16_OFFSET,
|
||||
JSP_DOM_VALUE,
|
||||
JSP_DOM_WHOLE_TEXT,
|
||||
JSP_DOM_XML_ENCODING,
|
||||
JSP_DOM_XML_STANDALONE,
|
||||
JSP_DOM_XML_VERSION,
|
||||
};
|
||||
#endif
|
||||
|
Loading…
Reference in New Issue
Block a user