Commit graph

302 commits

Author SHA1 Message Date
Jack Moffitt
c6ab60dbfc Cargoify servo 2014-09-08 20:21:42 -06:00
MechaXL
e2bfdb30a0 Implement document.lastModified (fixes #2972, #3127). 2014-09-04 13:44:02 +02:00
Ms2ger
ee39685051 Move the script type and language checks into HTMLScriptElement.
This is IMO a more sensible place for them to live, and prepares for the
demise of hubbub_html_parser.rs, as we move to html5ever.
2014-09-02 09:00:41 +02:00
Manish Goregaokar
64f05116fc Merge pull request #3131 from Manishearth/image
Load bare images within an HTML document (#3108); r=Ms2ger
2014-08-26 19:07:45 +05:30
Manish Goregaokar
22ed3d620d Load bare images within an HTML document (#3108) 2014-08-26 17:09:11 +05:30
Sean McArthur
bc129fee34 check the type/language of script elements 2014-08-21 10:34:12 -07:00
Ms2ger
9501d2e451 Make Attr::local_name an Atom. 2014-08-16 12:13:02 +02:00
Jack Moffitt
7a4321d649 Upgrade Rust. 2014-08-08 19:11:53 -06:00
Jack Moffitt
b91e6f30e0 Upgrade Rust. 2014-08-02 21:11:47 -06:00
Ms2ger
944d8b00b0 Call the generated rather than the hand-written traits (fixes #2936). 2014-07-27 23:00:17 +02:00
Ms2ger
e363b6fcc4 Avoid an unnecessary clone of the base URL in parse_html(). 2014-07-24 12:36:53 +02:00
Adenilson Cavalcanti
67f43e2b67 Move Parser creation to its own function (issue #849).
This is the first step to implement innerHTML, as we need a way
create and initialize a parser object while setting the received
DOMString (which may be either text/html/whatever).
2014-07-22 15:36:45 -07:00
Adenilson Cavalcanti
ffbb87b8a1 Recycle use of a local variable and remove what seems to be 2 extraneous URL objects. 2014-07-21 15:40:55 -07:00
Simon Sapin
6917fbf28e Used rust-url directly instead of servo_util::url
The latter now only calls the former.
2014-07-21 20:22:29 +01:00
Simon Sapin
dc49f4fda6 Start dogfooding rust-url. Fix #1673. 2014-07-21 20:21:35 +01:00
Josh Matthews
548946b800 Merge pull request #2777 from Manishearth/try_parse_url
Don't fail on parsing URLs in the html parser
2014-07-07 12:17:54 -04:00
Manish Goregaokar
a0e413cf1a Don't fail on parsing URLs in the html parser 2014-07-07 20:28:55 +05:30
Ms2ger
7852bcd626 Print a more helpful debug message when creating an element in the HTML parser.
Using {:?} prints a debugging representation such as

  collections::string::String{
    vec: collections::vec::Vec<u8>{
      len: 4u,
      cap: 4u,
      ptr: (0x7f75670285d8 as *mut ())
    }
  }

which is not very helpful.
2014-07-07 16:52:48 +02:00
Tetsuharu OHZEKI
975fee82da Remove needless mutabilities from script crate. 2014-06-22 21:22:58 +09:00
Ms2ger
c90a8529c5 Use internal mutability for Attr::value. 2014-06-22 20:39:21 +09:00
Edit Balint
94ec3cde8a Split Page code out of script_task.rs #2530 2014-06-13 19:28:57 +02:00
Ms2ger
ed333ad8c3 Pass immutable document to parse_html. 2014-06-11 22:57:54 +02:00
Ms2ger
288e0bc877 Use internal mutability for CharacterData::data. 2014-06-11 19:51:07 +02:00
Ms2ger
d230077f9f Stop mutating Element::namespace. 2014-06-11 19:51:07 +02:00
Jack Moffitt
629c4c6afe Upgrade Rust. 2014-06-05 09:58:59 -06:00
Tetsuharu OHZEKI
59ed832fa6 Remove needless '&mut self' from element.rs. 2014-06-03 03:27:28 +09:00
bors-servo
59cef940e8 auto merge of #2535 : saneyuki/servo/mut, r=jdm
Related #2514
2014-06-01 16:19:20 -04:00
Tetsuharu OHZEKI
49362aa255 Remove HTMLMainElement.
https://github.com/mozilla/servo/issues/2541
2014-06-02 04:40:46 +09:00
Tetsuharu OHZEKI
3819ebb740 Remove needless '&mut self' from node.rs. 2014-06-02 04:28:04 +09:00
Manish Goregaokar
5f860bb612 Request header and postdata support for XHR 2014-05-28 20:49:13 +05:30
Ms2ger
eaedeb07cb Update Rust. 2014-05-22 16:36:40 -06:00
Glenn Watson
f5c2f7e835 Add various base html elements to parser and test. Fixes #703. 2014-05-17 05:59:25 +10:00
Ms2ger
cb9d875aef Handle all attributes coming from the HTML parser (fixes #1976). 2014-05-13 12:28:15 +02:00
Ms2ger
d095c42eaf Move the loading of documents in iframes into HTMLIFrameElement.
Right now, the load is kicked off inside the parser glue. This is unfortunate
for several reasons:

1) we'd like to replace the current parser (libhubbub) by our own parser,
   written in Rust, so code intertwined with the parser will have to be
   rewritten;
2) it is impossible to support dynamically (i.e. from script) created iframes
   in this way;
3) the code flow around loading subdocuments is complicated needlessly.

This commit adds the constellation channel (on which the message to actually
load the document is sent) as a field on the Page, to allow HTMLIFrameElement
to access it.

In rewriting the code, support for dynamically created iframes is added, and
a task failure is avoided when the value of the src attribute can not be
parsed.
2014-05-12 21:21:03 +02:00
Ms2ger
8e9e930e3d Remove unused and misnamed url field on HTMLIFrameElement. 2014-05-11 20:37:55 +02:00
Guro Bokum
04c807dd53 Convert as many of Page's RefCell fields to Cell as possible (fixes #1990). 2014-05-09 23:52:06 +02:00
bors-servo
0a647baacb auto merge of #2355 : glennw/servo/http-fail-errors, r=jdm
...during task failure.
2014-05-08 11:16:41 -04:00
Glenn Watson
376d5f4a08 Allow resource load failures to send an error string which is reporting during task failure. 2014-05-08 07:43:45 +10:00
Glenn Watson
51ef2f06ba Rename from_unrooted to from_temporary. Fixes #2332. 2014-05-07 09:25:32 +10:00
Matt Murphy
af920f442b Convert Vec::new() to vec!() 2014-05-04 23:16:18 +02:00
Matt Murphy
c174a40afd ~[] to Vec in net/resource_task.rs 2014-05-04 23:16:18 +02:00
Matt Murphy
dccea25a8a ~[] to Vec in script/html/hubbub_html_parser.rs 2014-05-04 23:16:17 +02:00
Josh Matthews
91278da9dd Address review comments. 2014-05-03 14:18:31 -04:00
Josh Matthews
7b3e6d1f21 Remove all root collections. 2014-05-03 14:18:31 -04:00
Josh Matthews
522d3f167b s/Unrooted/Temporary/g 2014-05-03 14:18:31 -04:00
Josh Matthews
109410900c Move all methods on T to JSRef<T> or JS<T> as appropriate. 2014-05-03 14:18:30 -04:00
Josh Matthews
7daa97c7e5 Remove abstract_self. 2014-05-03 14:18:30 -04:00
Josh Matthews
76783b029e Move WebIDL methods to traits implemented by JSRef types. 2014-05-03 14:18:30 -04:00
Josh Matthews
d7b96db33c Implement safe rooting strategy via Unrooted, Root, JSRef, and JS. 2014-05-03 14:18:30 -04:00
Josh Matthews
ffdc3f5b32 Turn on GC all the time. Fix rooting errors during parsing and storing timers. Fix borrow errors during tracing. 2014-05-03 14:18:30 -04:00