aboutsummaryrefslogtreecommitdiffstats
path: root/src/components/script/script_task.rs
Commit message (Collapse)AuthorAgeFilesLines
...
* Add a LoadComplete message so that script informs the constellation,Lars Bergstrom2014-01-301-3/+5
| | | | | | | which can then inform the compositor (and anyone else, later) about the completion of loading a page. This is important for ref tests, which should not emit a PNG until load has completed, even if we perform a composite before then.
* Implement document.URL & document.documentURIBruno de Oliveira Abinader2014-01-301-1/+1
| | | | | | | | Specs: http://dom.spec.whatwg.org/#dom-document-url http://dom.spec.whatwg.org/#dom-document-documenturi This is a sub-task for #1428.
* Move script::dom::namespace into util, in order to use it from style later.Simon Sapin2014-01-251-1/+1
|
* Change `get_attr()` to `get_attr_val_for_layout()`.Jack Moffitt2014-01-221-6/+6
| | | | | | | | 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`.
* When `window.close()` is called, we should just ask the compositor to exitLars Bergstrom2014-01-151-6/+7
| | | | | | | | | normally. The old code made the mistake of attempting to shutdown the associated pipelines itself, which caused race conditions with the constellation and compositor, as they expect to be able to drain their message queues before exiting.
* script: Stop trusting pointers to DOM nodes that layout provides.Patrick Walton2014-01-141-22/+22
| | | | | | | Pointers to DOM nodes from layout could go stale if incremental reflow does not correctly destroy dead nodes. Therefore, we ask the JavaScript garbage collector to verify that each DOM node is indeed a valid pointer before calling event handlers on it, and fail otherwise.
* add names for all servo spawned taskszmike2014-01-131-1/+2
| | | | | | | | * add servo_util::task::{spawn_named,spawn_with_named} functions * add name param for spawn_listener and spawn_conversation functions this should resolve #1169
* Upgrade to latest Rust.Jack Moffitt2014-01-121-83/+46
|
* auto merge of #1409 : pcwalton/servo/fix-get-bounding-client-rect, r=jdmbors-servo2014-01-071-20/+15
|\ | | | | | | | | | | This fixes the `getBoundingClientRect()` content test. r? @jdm
| * script: Don't do anything before the window size comes in.Patrick Walton2013-12-131-20/+15
| | | | | | | | This fixes the `getBoundingClientRect()` content test.
* | Pass a Namespace to Element::get_attr.Ms2ger2013-12-231-2/+3
| |
* | layout: Stop exposing raw `Element` types to layout as well.Patrick Walton2013-12-171-1/+0
| | | | | | | | | | This should make layout memory-safe as is, though we will need to do more stuff for incremental reflow and parallelism.
* | script: Eliminate the phantom type in favor of just whitelisting methodsPatrick Walton2013-12-171-4/+3
| | | | | | | | | | | | | | that layout can safely call. This is simpler. Currently, the set of methods is not safe, but I plan to lock it down more soon.
* | script: Make trees less genericPatrick Walton2013-12-171-1/+1
|/
* layout: Stop going to the DOM for iframe sizesPatrick Walton2013-12-131-4/+4
|
* constellation: Stop using futures for frame sizes.Patrick Walton2013-12-131-44/+66
| | | | | | This will allow us to stop going to the DOM in order to handle iframe sizing. Instead we can just store the pipeline and frame IDs of iframes inside the flow tree itself.
* Mark some rust files as non-executable.Ms2ger2013-12-131-0/+0
|
* Allow setting id, class, style without a full reflowKeegan McAllister2013-12-121-3/+0
| | | | | | | | Instead we do selector matching again, then diff the style structs to set the "restyle damage" bits which are used to prune reflow traversals. Also don't force a reflow when timers finish, because individual DOM methods should already take care of that.
* Get rid of reflow_allKeegan McAllister2013-12-121-18/+10
| | | | This refactoring should not alter behavior.
* Fix #1264: support namespaced attribute selectors.Simon Sapin2013-12-101-2/+2
|
* Reflow with full style damage when content changesKeegan McAllister2013-12-091-1/+2
| | | | Fixes #664.
* Implement local bookmark(hashtag) for Acid2. With @joonwonleejune0cho2013-12-011-2/+58
| | | | Support hashtag through link (e.g. <a href="#top">)
* Rewrite flow construction to be incrementalizable and parallelizable.Patrick Walton2013-11-181-42/+77
| | | | | | | | | | | | This replaces flow construction with a strict bottom-up tree traversal, allowing for parallelism. Each step of the traversal creates a flow or a `ConstructionItem`, similar to how Gecko works. {ib} splits are handled by not creating `InlineFlow`s until the containing block is reached. This should be able to be incrementalized by storing the `Flow` from layout to layout, and performing fixups during flow construction and/or wiping containing blocks in a previous pass.
* Make the HTML parser parse into the document rather than an element.Ms2ger2013-11-171-6/+3
| | | | This removes the duplicate html element.
* Remove type_id arguments from Event::new and UIEvent::new.Ms2ger2013-11-141-2/+2
|
* Stop passing DOMStrings via borrowed pointer. (#1201)Tetsuharu OHZEKI2013-11-141-1/+1
|
* Don't pass nullable strings to native DOM methods that want non-nullable ↵Ms2ger2013-11-121-1/+1
| | | | strings. Fixes #1207.
* Add a spec-incompliant load event.Josh Matthews2013-11-111-0/+11
|
* auto merge of #1163 : metajack/servo/kmc-rust-upgrade, r=kmcallisterbors-servo2013-10-311-13/+12
|\ | | | | | | | | | | Most work courtesy of @kmcallister. I already reviewed Keegan's work, so just the last two commits need attention.
| * Store the Page's final URL before parsingKeegan McAllister2013-10-311-2/+1
| | | | | | | | | | | | | | | | | | We were parsing URLs like //bits.wikimedia.org/static-1.22wmf22/skins/vector/images/search-ltr.png?303-4 as local filenames because HTMLImageElement::update_image didn't have a current_url to pass to make_url().
| * fmt! -> format!Keegan McAllister2013-10-311-11/+11
| |
* | Make Document a Node.Josh Matthews2013-10-311-1/+1
|/
* Revert "Make Document a Node." for breaking Acid1Patrick Walton2013-10-241-1/+1
| | | | | | | | This reverts commit 4e47d59165d186d0938fe9ffd726b2c1b83d50f4. Conflicts: src/components/script/dom/domparser.rs
* Make Document a Node.Josh Matthews2013-10-241-1/+1
|
* Update to latest Rust.Jack Moffitt2013-10-211-6/+6
|
* Replace Document::{with_base, with_mut_base} by Document::{document, ↵Ms2ger2013-10-211-9/+5
| | | | mut_document}.
* Remove special-casing of URLs ending in ".js"Keegan McAllister2013-10-171-27/+0
| | | | | | | This was a very old (May 2012) testing feature which used std::io::read_whole_file rather than our normal resource-loader mechanism. We can implement javascript: URLs later.
* auto merge of #1077 : kmcallister/servo/jsstr, r=jdmbors-servo2013-10-171-1/+2
|\ | | | | | | This doesn't resolve the big questions of how Servo will represent strings; it's just about doing the conversion correctly for our existing types.
| * Pass scripts as ~str to support non-ASCII string literals etc.Keegan McAllister2013-10-161-1/+2
| | | | | | | | | | Of course scripts on the Web are not always encoded as UTF-8 and we will have to deal with that at some point.
* | Move Element::get_attr to a trait defined in util::treeSimon Sapin2013-10-161-1/+1
|/ | | | … and add a get_local_name() method to that trait.
* Issue #1071 - Ensure that Documents always have a non-null Window.Ms2ger2013-10-161-1/+1
|
* Make Document::root private, in preparation for removing it as part of ↵Ms2ger2013-10-131-3/+5
| | | | making Document a Node.
* Issue #888 - Node's owner document should never be None.Ms2ger2013-10-101-5/+5
|
* Rename {get,set}_wrapper to {get,set}_jsobject. v1Bobby Holley2013-10-091-1/+1
|
* Rename get_wrappercache() to reflector(). v1Bobby Holley2013-10-091-1/+1
| | | | I also updated some variable names in the codegen.
* Rename CacheableWrapper to Reflectable.Bobby Holley2013-10-091-1/+1
|
* Remove unnecessary mutability.Ms2ger2013-10-061-1/+1
|
* Don't require passing a root element to Document::new (needed for issue #888).Ms2ger2013-10-051-33/+50
|
* Wait for any layout tasks to complete in a page tree before a handling a ↵Josh Matthews2013-10-021-1/+3
| | | | pipeline's exit message.
* Run script in its own thread to avoid starving other tasksBrian Anderson2013-10-011-5/+10
|