Bruno de Oliveira Abinader
3a8a0927e2
HTMLCollection::create returns live collections by default
2014-03-26 09:12:38 -04:00
Bruno de Oliveira Abinader
e95aa0febd
Support live HTMLCollection for Document collections
...
The following interface methods now return live collections:
Document.{images,embeds,plugins,links,forms,scripts,anchors,applets}
2014-03-26 09:11:13 -04:00
Ms2ger
038a195ead
Move attributes-related functions onto JS<Element>.
2014-03-20 19:42:42 +01:00
Tetsuharu OHZEKI
0fccf5e386
Split TCast::to into TCast::to_unchecked and TCast::to.
2014-03-20 23:41:59 +09:00
bors-servo
7f188500a1
auto merge of #1915 : Ms2ger/servo/wrap-return-js, r=jdm
...
This lets us avoid the sketchy tricks in JS::new and Window::new, where we
kept an unsafe pointer to the native object across the Wrap call that
consumed the owned pointer.
2014-03-19 19:01:48 -04:00
Josh Matthews
64c0de9fe7
Warning police.
2014-03-18 09:31:22 -05:00
Lars Bergstrom
bbac8aa5c3
Rust upgrades
2014-03-18 09:30:35 -05:00
Ms2ger
4ad3b6ccd1
Return a JS<T> from *Binding::Wrap rather than a JSObject.
...
This lets us avoid the sketchy tricks in JS::new and Window::new, where we
kept an unsafe pointer to the native object across the Wrap call that
consumed the owned pointer.
2014-03-14 13:06:51 +01:00
Bruno de Oliveira Abinader
5eee401403
Added Document's quirks mode getter
2014-03-13 12:34:31 -04:00
Ms2ger
a15cac53bc
Don't use the Untraceable fields outside the module they're defined in.
...
This pattern will become illegal with the next Rust upgrade.
2014-03-12 14:30:19 +01:00
Bruno de Oliveira Abinader
38ba71ceb1
Replaced Document::createHTMLDocument in favor of HTMLCollection helpers
2014-03-07 11:10:56 -04:00
Bruno de Oliveira Abinader
d010861b75
Implemented {Document,Element}.getElementsByClassName
2014-03-07 11:10:56 -04:00
Bruno de Oliveira Abinader
e1499b610e
Implemented {Document,Element}.getElementsByTagNameNS
2014-03-07 11:10:56 -04:00
Bruno de Oliveira Abinader
d22dbb53ca
Implemented {Document,Element}.getElementsByTagName
2014-03-07 11:10:55 -04:00
bors-servo
81ef420e3f
auto merge of #1819 : Ms2ger/servo/createHTMLCollection-JS, r=jdm
2014-03-05 10:19:31 -05:00
bors-servo
da6a571f9e
auto merge of #1811 : Ms2ger/servo/Wrap_, r=jdm
2014-03-05 09:31:44 -05:00
Ms2ger
7ecc39e9ba
Rewrite Document::create_collection to work better with createNodeList.
2014-03-05 12:19:28 +01:00
Ms2ger
cd1d81e402
Pass a JS<Element> to the callback in createHTMLCollection.
2014-03-05 12:00:23 +01:00
Ms2ger
787108deaf
Pass &JS<Window> to the Wrap functions in codegen.
2014-03-04 15:08:44 +01:00
Ms2ger
23b7277b54
Pass &JS<Window> to reflect_dom_object.
2014-03-04 14:13:58 +01:00
Manish Goregaokar
8b425fb8cf
Make document.getElementsByTagname return a NodeList; consolidate element collection to collectElement; fix #1744
2014-03-04 02:19:32 +05:30
Saurabh Anand
5c5cb3e9a7
Move Error, Fallible, ErrorResult out of utils.rs ( fixes #1749 )
2014-02-28 13:32:00 +05:30
bors-servo
1a171129dc
auto merge of #1771 : lpy/servo/issue1742, r=Ms2ger
...
see #1742
2014-02-27 05:55:47 -05:00
lpy
f9f82ff4e6
Add check for non-Text children for document.title.( fixes #1742 )
2014-02-27 14:40:35 +08:00
Ms2ger
25ee5270d1
Only register the new ID from after_set_attr, and remove update_idmap.
2014-02-26 14:50:57 +01:00
Ms2ger
33792db657
Move ID management on binding to and unbinding from tree into Element.
2014-02-26 14:50:57 +01:00
Ms2ger
2cbf7f4c7a
Rewrite Document::SetTitle to use a match.
2014-02-25 09:34:29 +01:00
Ms2ger
870ccd95d2
Remove DocumentTypeId.
2014-02-24 22:35:28 +01:00
Ms2ger
5ede84fa46
Remove document::DocumentType ( fixes #1730 ).
2014-02-24 22:28:27 +01:00
Ms2ger
7190feb5e3
Move HTMLDocument members to Document.
2014-02-24 22:17:33 +01:00
Ms2ger
2c8107e811
Remove methods from IDL that don't do anything useful.
2014-02-24 22:12:04 +01:00
Josh Matthews
625325434b
Implement JSManaged for DOM objects.
2014-02-24 15:16:42 -05:00
Ms2ger
6681476713
Use push_str instead of operator + for efficiency.
2014-02-16 10:25:12 +01:00
Ms2ger
e45b7fa22d
Use eq() and eq_slice() less, and map_default() more.
2014-02-16 10:24:24 +01:00
Adam Sinnett
ffcd3833de
Change Text, Comment and ProcessingInstructions parent name from element to characterdata
...
All other node's parent type names reflect the actual type of the parent. This change extends that convention to the indicated nodes.
closes #1594
2014-02-15 13:52:33 -08:00
Ms2ger
59184bf6e1
Move DOMString into servo_util.
2014-02-14 12:48:51 +01:00
Bruno de Oliveira Abinader
6fde4f82e7
Added refs to Document's DOM spec
2014-02-10 17:17:07 -04:00
bors-servo
14ee9218e4
auto merge of #1634 : brunoabinader/servo/document-fromnode, r=jdm
...
TSIA.
@jdm mentioned to use ```AbstractDocument::from_box``` internally, though.
2014-02-06 15:46:41 -05:00
Bruno de Oliveira Abinader
b19e31942e
Provide AbstractDocument::from_node(node: AbstractNode)
...
TSIA.
2014-02-06 16:33:16 -04:00
Bruno de Oliveira Abinader
ac8c659d2b
Implement document.createProcessingInstruction
...
Spec:
http://dom.spec.whatwg.org/#dom-document-createprocessinginstruction
This is a sub-task for #1428 .
2014-02-06 16:11:31 -04:00
Bruno de Oliveira Abinader
a6c897e445
Implement document.characterSet
...
Spec:
http://dom.spec.whatwg.org/#dom-document-characterset
This is a sub-task for #1428 .
2014-02-06 07:46:24 -04:00
Bruno de Oliveira Abinader
56572a2814
Implement document.compatMode
...
Spec:
http://dom.spec.whatwg.org/#dom-document-compatmode
This is a sub-task for #1428 .
2014-01-30 19:12:19 -04:00
Bruno de Oliveira Abinader
43416ef91f
Implement document.URL & document.documentURI
...
Specs:
http://dom.spec.whatwg.org/#dom-document-url
http://dom.spec.whatwg.org/#dom-document-documenturi
This is a sub-task for #1428 .
2014-01-30 10:41:24 -04:00
Simon Sapin
624e2714d4
Move script::dom::namespace into util, in order to use it from style later.
2014-01-25 12:14:06 -08:00
bors-servo
d11e431887
auto merge of #1533 : metajack/servo/unsafe-get-attr, r=jdm
...
The old code was used by both layout and script, but was erroneously
borrowing for the layout case (which causes parallelism
problems). script now uses only `value_ref()` or `get_attribute()`, and
layout now has its own unsafe version that dances around the borrows of
`@mut Attr`.
2014-01-22 16:28:20 -08:00
Jack Moffitt
c443bcbfff
Change get_attr()
to get_attr_val_for_layout()
.
...
The old code was used by both layout and script, but was erroneously
borrowing for the layout case (which causes parallelism
problems). script now uses only `value_ref()` or `get_attribute()`, and
layout now has its own unsafe version that dances around the borrows of
`@mut Attr`.
2014-01-22 17:02:21 -07:00
Bruno de Oliveira Abinader
1067da7df8
Basic support for Document::contentType
...
Spec:
http://dom.spec.whatwg.org/#dom-document-contenttype
This is a subtask for #1428 , #1510 and #1526 .
2014-01-21 12:48:09 -04:00
Bruno de Oliveira Abinader
cdf29d4394
Remove Document's unused 'title'
...
There is no current use for this variable.
This is a subtask for #1428 .
2014-01-17 10:00:50 -04:00
Bruno de Oliveira Abinader
60dd40f412
Add DOMImplementation skeleton
...
Creates a DOMImplementation struct corresponding to DOMImplementation
WebIDL. Also implements a getter for Document::implementation.
Closes #1486 .
2014-01-14 13:20:36 -04:00
Bruno de Oliveira Abinader
742ad9cd24
Implement Document::doctype
...
Closes #1482 .
2014-01-13 15:45:34 -04:00