update the DOM API so that we implement using the property style access of properties which work natively in JS and avoid using getter/setter methods in the DOM library so that they can easily compile to JS too from the same org.w3c.dom API on the JVM

This commit is contained in:
James Strachan
2012-06-01 07:45:55 +01:00
parent 570f9d765d
commit bc7104a8fe
5 changed files with 373 additions and 236 deletions
+2 -2
View File
@@ -60,7 +60,7 @@ class DomBuilderTest() : TestCase() {
assertEquals(1, doc["#id2"].size())
assertEquals(1, doc["#id3"].size())
val root = doc.rootElement
val root = doc.documentElement
if (root == null) {
fail("No root!")
} else {
@@ -120,7 +120,7 @@ class DomBuilderTest() : TestCase() {
} else {
fail("Not an Element $grandChild")
}
val children = doc.rootElement.children()
val children = doc.documentElement.children()
val xml = nodesToXmlString(children)
println("root element has children: ${xml}")
assertEquals(1, children.size())