Commit graph

65 commits

Author SHA1 Message Date
Matt Brubeck
fe123ad07c Switch to synchronous script loading
This removes the old code for asyncronously loading scripts during HTML
parsing and then executing them afterward.

Fixes #3356.
2014-10-29 14:31:47 -07:00
Clark Gaebel
a8f80b89f4 layout: Implement flow tree dumping with RUST_LOG=debug is on.
r? @pcwalton
2014-10-28 10:14:12 -07:00
Ray Clanan
85f746f9b9 Rename untraceable!() to no_jsmanaged_fields!(). References issue #3671 2014-10-23 21:33:32 -04:00
Josh Matthews
539c21f380 Implement Document.readyState. Prevent iframes from notifying the compositor after the initial parse. Fixes #1720. Fixes #3738. 2014-10-23 10:55:59 -04:00
Edit Balint
daf9e59869 Make DOM getters that return &JS<T> return Temporary<T> instead #3707 2014-10-22 19:05:25 +02:00
Tetsuharu OHZEKI
7e7c610837 Use DOMRefCell for Node.
Altough LayoutDataRef is touched, we don't use DOMRefCell in it becasuse
it's expected to manipulate in other task.
2014-10-22 10:01:01 +09:00
Clark Gaebel
a5bb2f299f more efficient preorder DOM traversals 2014-10-21 10:01:15 -07:00
Keegan McAllister
9da7679367 Use html5ever for HTML parsing 2014-10-16 13:06:34 -07:00
bors-servo
9af0900060 auto merge of #3684 : Manishearth/servo/dom_struct, r=jdm
This attribute implies #[jstraceable], #[privatize], and #[must_root].
2014-10-15 23:24:20 -06:00
Manish Goregaokar
3f2cbb275b Use #[dom_struct] everywhere 2014-10-16 10:20:18 +05:30
Tetsuharu OHZEKI
0d447394b2 Removes Node.unsafe_get_flags().
`Node.unsafe_get_flags()` returns `*const NodeFlags`,
but `NodeFlags` has only `u8` length.
We should just returns a raw value instead of any pointers.
2014-10-16 11:04:17 +09:00
bors-servo
56989b8dec auto merge of #3640 : cgaebel/servo/incremental-flow-construction, r=pcwalton
This also hides the not-yet-working parts of incremental reflow behind a runtime
flag. As I get the failing reftests passing, I'll send pull requests for them one
by one.
2014-10-14 16:51:30 -06:00
Clark Gaebel
f552e2f750 try to reset flows which need reflow, since reflow isn't yet idempotent 2014-10-14 10:33:46 -07:00
Patrick Walton
ee2ccc4f87 script: Use atom comparison in more places, especially for attributes.
75% improvement in style recalc for Guardians of the Galaxy.
2014-10-14 10:32:40 -07:00
Tim Taubert
cbe50f1f14 Privatize Element 2014-10-13 13:25:44 +02:00
Tim Taubert
28061b1c91 Privatize Node 2014-10-13 13:25:44 +02:00
Tim Taubert
8825296869 Privatize Document 2014-10-13 13:25:43 +02:00
Tim Taubert
d0addd36bb Privatize ProcessingInstruction 2014-10-13 13:25:43 +02:00
Tim Taubert
df60f8b2c5 Privatize EventTarget and EventListenerEntry 2014-10-13 13:25:43 +02:00
Tim Taubert
ba073d7e99 Privatize DocumentType 2014-10-13 13:25:43 +02:00
Tim Taubert
e15f8cb37f Privatize Comment 2014-10-13 13:19:05 +02:00
Tim Taubert
78fef7eec5 Privatize Attr 2014-10-13 13:18:57 +02:00
Tim Taubert
9a52bb8310 Privatize InheritTypes 2014-10-13 11:13:12 +02:00
Clark Gaebel
d12c6e7383 Incremental Style Recalc
This patch puts in the initial framework for incremental reflow. Nodes' styles
are no longer recalculated unless the node has changed.

I've been hacking on the general problem of incremental reflow for the past
couple weeks, and I've yet to get a full implementation that actually passes all
the reftests + wikipedia + cnn. Therefore, I'm going to try to land the different
parts of it one by one.

This patch only does incremental style recalc, without incremental flow
construction, inline-size bubbling, reflow, or display lists. Those will be coming
in that order as I finish them.

At least with this strategy, I can land a working version of incremental reflow,
even if not yet complete.

r? @pcwalton
2014-10-09 12:55:21 -04:00
Tim Taubert
35f8270c64 Remove unnecessary deref()s (fixes #3586) 2014-10-09 15:01:54 +02:00
Tim Taubert
b9e23563bb Support [*|attr], attribute selectors in any namespace (fixes #1558) 2014-10-08 11:01:31 +02:00
Gilles Leblanc
3a5a66d54e Take the prefix from createElementNS into account for HTML elements
Fixes #3139
2014-10-06 22:49:49 -04:00
Manish Goregaokar
a8f96ddfb2 Remove Traceable/Untraceable from node.rs 2014-10-05 22:36:08 +05:30
Manish Goregaokar
4f362ab5e6 Remove Untraceable/Traceable from document.rs 2014-10-05 21:58:59 +05:30
Manish Goregaokar
4f574b4732 Remove Traceable from characterdata.rs 2014-10-05 21:33:43 +05:30
bors-servo
bae5440689 auto merge of #3531 : Ms2ger/servo/MutNullableJS, r=Ms2ger
Extracted from #3527.
2014-10-01 09:09:28 -06:00
Josh Matthews
54fcab61d6 Implement MutNullableJS for mutable, nullable member pointers to DOM objects. 2014-10-01 17:06:23 +02:00
Cameron Zwarich
72656717d4 Remove an extra lifetime parameter on NodeHelpers 2014-10-01 02:07:46 -07:00
Cameron Zwarich
78791af7d6 Convert the NodeHelpers trait to use self methods 2014-09-30 23:42:03 -07:00
Cameron Zwarich
79b4ec99b4 Convert TNode / TElement to use self methods rather than &self 2014-09-30 21:26:19 -07:00
Cameron Zwarich
e894499c17 Disambiguate methods without using trait objects 2014-09-30 21:22:24 -07:00
Cameron Zwarich
4ef0f39c78 Remove a prefix from a method name by manually resolving methods 2014-09-30 21:21:00 -07:00
Cameron Zwarich
3953456b61 Convert a method from &JSRef to JSRef
This also removes the unnecessary formation of a trait object.
2014-09-30 15:55:05 -07:00
Simon Sapin
b3245fa407 Upgrade to rustc d2b30f7d3 2014-09-23 2014-09-29 17:41:45 +01:00
Cameron Zwarich
61ae80e186 Add an extra lifetime parameter to TElement / TNode
This isn't used for anything yet, but it's easier to propagate this
change in a separate commit.
2014-09-27 11:14:10 -07:00
bors-servo
a35212410a Merge pull request #3496 from zwarich/disabled-state-helpers-jsref
Convert &JSRef -> JSRef in DisabledStateHelpers

Reviewed-by: jdm
2014-09-26 20:24:33 -06:00
Cameron Zwarich
4bf2a88ae2 Convert &JSRef -> JSRef in DisabledStateHelpers 2014-09-26 15:58:36 -07:00
Cameron Zwarich
4f32d54fd8 Convert &JSRef -> JSRef for the PrivateNodeHelpers trait 2014-09-26 15:46:37 -07:00
Manish Goregaokar
6f6a62e967 Address review comments 2014-09-24 19:35:41 +05:30
Manish Goregaokar
cc44a3b064 Use JSTraceable everywhere 2014-09-24 05:44:49 +05:30
Keegan McAllister
dc86e83654 Eliminate warnings 2014-09-20 13:00:55 -07:00
Keegan McAllister
a640a7c5c3 Upgrade to rustc 0.12.0-pre (4d2af3861 2014-09-17 15:51:11 +0000) 2014-09-20 13:00:06 -07:00
Cameron Zwarich
2c8d51a37c More progress in the &JSRef -> JSRef conversion
Change all of the <Class>Methods traits to take `self` instead of
`&self`.
2014-09-20 11:54:10 -07:00
Adenilson Cavalcanti
7581335232 Move is_void() Element method together with the other struct methods,
it becomes part of ElementHelpers.
2014-09-20 10:24:57 -07:00
Tetsuharu OHZEKI
de0866ab42 Use Untraceable<T> to hold LayoutDataRef instead of manual Encodable implementation. 2014-09-20 15:19:01 +09:00