Index: DOMTestCase.js =================================================================== RCS file: /sources/public/2001/DOM-Test-Suite/ecmascript/DOMTestCase.js,v retrieving revision 1.21 diff -r1.21 DOMTestCase.js 2c2 < Copyright (c) 2001 World Wide Web Consortium, --- > Copyright (c) 2001-2003 World Wide Web Consortium, 215,216c215,216 < if (url == "staff" && !(this.contentType == "text/xml" || this.contentType == 'image/svg+xml')) { < throw "Tests using staff document are only supported for XML or SVG processors"; --- > if (url == "staff" && this.contentType == "text/html") { > throw "Tests using staff document are not supported by HTML processors"; 257a258,259 > > 374a377,378 > > 562a567,571 > for (var i = 0; i < this.fixedAttributeNames.length; i++) { > if (this.fixedAttributeNames[i] == attr) { > return this.fixedAttributeValues[i]; > } > } 574a584,654 > > function DOM3LSBuilder() { > this.contentType = "text/xml"; > > this.configurableAttributeNames = [ ]; > this.configurableAttributeValues = [ ]; > this.fixedAttributeNames = [ "validating", "ignoringElementContentWhitespace", "signed", > "hasNullString", "expandEntityReferences", "coalescing", "namespaceAware" ]; > this.fixedAttributeValues = [ false, false, true, true, false, false, true ]; > > this.contentType = "text/xml"; > this.supportedContentTypes = [ > "text/xml", > "image/svg+xml", > "application/xhtml+xml", > "text/mathml" ]; > > this.async = true; > this.supportsAsyncChange = true; > > this.docs = new Array(); > this.docnames = new Array(); > this.exception = null; > } > > DOM3LSBuilder.prototype.preload = function(frame, varname, url) { > if (this.async) { > var domimpl = document.implementation; > var dombuilder = domimpl.createDOMBuilder(2, null); > dombuilder.addEventListener("load", loadComplete, false); > var uri = fileBase + url + getSuffix(this.contentType); > var doc = dombuilder.parseURI(uri); > this.docs[this.docs.length] = doc; > this.docnames[this.docnames.length] = varname; > return 0; > } > return 1; > } > > DOM3LSBuilder.prototype.load = function(frame, varname, url) { > if (this.async) { > for(i = 0; i < this.docnames.length; i++) { > if (this.docnames[i] == varname) { > return this.docs[i]; > } > } > return null; > } > var dombuilder = document.implementation.createDOMBuilder(1, null); > var uri = fileBase + url + getSuffix(this.contentType); > return dombuilder.parseURI(uri); > } > > > DOM3LSBuilder.prototype.getImplementationAttribute = function(attr) { > for (var i = 0; i < this.fixedAttributeNames.length; i++) { > if (this.fixedAttributeNames[i] == attr) { > return this.fixedAttributeValues[i]; > } > } > } > > > DOM3LSBuilder.prototype.toAutoCase = function(s) { > return s; > } > > DOM3LSBuilder.prototype.toAutoCaseArray = function(s) { > return s; > } > 590,591c670 < // return new DOM3LSBuilder(); < return new IFrameBuilder(); --- > return new DOM3LSBuilder();