Commit graph

150 commits

Author SHA1 Message Date
Ms2ger
793d87f07d Rewrite jsval_to_str and introduce jsval_to_domstring. 2013-11-09 14:49:15 +01:00
Ms2ger
610d1649cd Introduce jsid_to_str to simplify jsval_to_str callers that have an id. 2013-11-09 14:05:53 +01:00
Ms2ger
edd9c1d5eb Remove WrapNativeParent and nearby cleanup. 2013-11-06 21:56:36 +01:00
Ms2ger
4074412107 Pass a Reflector to WrapNewBindingObject instead of a Reflectable, and rename it GetReflector. 2013-11-06 17:52:59 +01:00
Josh Matthews
bb97fd13f3 Add Event and EventTarget hierarchy via gross AbstractFoo mechanism. 2013-11-05 12:58:28 -05:00
Josh Matthews
7ecf5abbbd Generate code for handling callbacks. Implement add/removeEventListener and hacky dispatchEvent proof-of-concept. 2013-11-05 12:58:28 -05:00
Josh Matthews
06b1db8818 Import unmodified callbacks-related codegen source from Gecko. 2013-11-05 12:57:02 -05:00
bors-servo
352acbb833 auto merge of #1163 : metajack/servo/kmc-rust-upgrade, r=kmcallister
Most work courtesy of @kmcallister.

I already reviewed Keegan's work, so just the last two commits need attention.
2013-10-31 16:34:14 -07:00
Keegan McAllister
e2b7885b73 fmt! -> format! 2013-10-31 14:58:55 -06:00
Josh Matthews
99a36cbeb6 Make Document a Node. 2013-10-31 13:34:44 -04:00
Ms2ger
2ca1eede9a Implement insertBefore and reimplement appendChild. 2013-10-29 21:48:28 +01:00
Patrick Walton
baba35adc9 Revert "Make Document a Node." for breaking Acid1
This reverts commit 4e47d59165.

Conflicts:

	src/components/script/dom/domparser.rs
2013-10-24 15:08:09 -07:00
Josh Matthews
4e47d59165 Make Document a Node. 2013-10-24 18:07:46 +02:00
Ms2ger
e418e4d830 Remove no-op implementations from Document and HTMLDocument. 2013-10-21 19:51:12 +02:00
bors-servo
8dd462c38c auto merge of #1091 : marcoscaceres/servo/master, r=jdm 2013-10-18 19:22:08 -07:00
Marcos Caceres
faf53fd05c Implemention of HTMLMainElement 2013-10-18 22:03:58 +01:00
Ms2ger
40fde80e1a Implement the no-argument Blob constructor. 2013-10-18 19:30:32 +02:00
Ms2ger
25cae74093 Remove unused aTriedToWrap argument. 2013-10-17 16:43:28 +02:00
Tetsuharu OHZEKI
0de35fdc2f Implement HTMLTableDataCellElement & HTMLTableHeaderCellElement. 2013-10-15 22:37:06 +09:00
Tim Taubert
189bb6c95f Remove View type parameter from DocumentType 2013-10-14 17:32:38 -07:00
Ms2ger
f4edbb6b2e Remove some type variables and an explicit dereference. 2013-10-12 16:08:45 +02:00
Ms2ger
438d121cd8 Implement DocumentFragment. 2013-10-12 15:14:09 +02:00
Tim Taubert
9fe9145be4 implement NodeList and consolidate common scope and context retrieval 2013-10-11 07:34:38 -07:00
Ms2ger
98cdf5c118 Implement Document.createComment. 2013-10-11 12:40:35 +02:00
Ms2ger
a5233f2bc4 Support Node.nodeType and Node.nodeValue. 2013-10-10 22:09:34 +02:00
Bobby Holley
c4bbc4cd37 Introduce mutable/immutable variants of reflector() with named lifetimes, and kill unsafe casts. 2013-10-10 13:11:24 +02:00
Ms2ger
04319fdb68 Issue #888 - Node's owner document should never be None. 2013-10-10 10:57:38 +02:00
Bobby Holley
6bf740d967 Rename {get,set}_wrapper to {get,set}_jsobject. v1 2013-10-09 12:13:18 +02:00
Bobby Holley
62ddac8b6f Rename get_wrappercache() to reflector(). v1
I also updated some variable names in the codegen.
2013-10-09 12:11:25 +02:00
Bobby Holley
0a0599ad9b Rename CacheableWrapper to Reflectable. 2013-10-09 12:03:18 +02:00
Josh Matthews
bc81716c30 Make proxy finalizers retrieve the DOM object from the right slot. 2013-10-02 01:43:14 -04:00
Josh Matthews
cb826f9920 Make proxy bindings generate trace and finalization hooks. 2013-09-30 22:14:27 -04:00
bors-servo
7ffcc29d54 auto merge of #955 : kmcallister/servo/bindings, r=metajack 2013-09-18 19:39:47 -07:00
Keegan McAllister
73c1a12f30 bindings: Return errors in Result rather than setting an out parameter
Fixes #909.
2013-09-18 18:07:37 -07:00
James Graham
29a75daa66 Add support for clearTimeout. 2013-09-19 00:02:41 +01:00
Keegan McAllister
4b0680a136 Replace our rust_box with std::unstable::raw::Box
This will keep us in sync with compiler changes.  In fact we had the 'prev' and
'next' fields in the wrong order (but we aren't using them).
2013-09-18 14:57:12 -07:00
Keegan McAllister
68ddc6b4ab Make DOMString an alias for Option<~str>
Fixes #898.
2013-09-18 14:46:42 -07:00
Josh Matthews
d465abdb1c Make all DOM manipulation wait until it's safe to do so (ie. all reflows for the page have completed). Fix a race where a newly-initiated reflow would be considered complete when receiving the completion notice for the previous reflow. 2013-09-16 23:41:34 -04:00
Josh Matthews
37787d55d0 Pass the AbstractNode into the Node.textContent setter. 2013-09-16 23:39:16 -04:00
Patrick Walton
76d288fe62 script: Implement image source setting from script and write a demo for this. 2013-09-12 18:03:11 -07:00
Josh Matthews
a410651fba Make Element.set_attr require an AbstractNode so we can always downcast. 2013-09-12 14:40:00 -07:00
bors-servo
5aa207a7f7 auto merge of #912 : brson/servo/longcat, r=jdm
This also comes with a longcat demo, including about 35k of images that I don't know the copyright status of.
2013-09-11 23:49:02 -07:00
Brian Anderson
42c6a53148 Implement getters and setters for img width and height properties 2013-09-11 22:08:44 -07:00
Josh Matthews
636c30affe Add trace hooks for Window and Document, and remove explicit rooting for the root DOM node. Fixes #901. 2013-09-11 12:18:23 -07:00
Jack Moffitt
227bb95213 Add document.createElement and document.createTextNode.
This re-uses the parser's node creation code. That could probably be put
somewhere nicer. Suggestions welcome!
2013-09-10 16:21:58 -06:00
Ilyong Cho
0d4cfd0eb9 Add node.appendChild 2013-09-10 12:39:58 +09:00
Ilyong Cho
bcd7c0b8c6 Add node.removeChild 2013-09-10 11:35:31 +09:00
Josh Matthews
da599c6ccf Make the global object be the Window object. Fixes #833. 2013-09-09 10:25:39 -07:00
Brian Anderson
13a3865e4e Update rust 2013-09-06 15:14:22 -07:00
Tom Schuster
e81fed7b58 Implement Navigator 2013-09-05 19:09:10 -04:00