Skip to content

Separate the DOM and layout into separate crates.#474

Merged
bors-servo merged 9 commits intoservo:masterfrom
pcwalton:separation
May 30, 2013
Merged

Separate the DOM and layout into separate crates.#474
bors-servo merged 9 commits intoservo:masterfrom
pcwalton:separation

Conversation

@pcwalton
Copy link
Copy Markdown
Contributor

pcwalton added 9 commits May 28, 2013 15:40
This is preparation for removing the `servo-` prefixes from the various
Servo components.
…data directly.

Nodes are now parameterized over a "View" type. The particular View type
determines which methods can be called. Layout data accessors and mutators are
only accessible to nodes with a LayoutView. The only way to convert a
`Node<ScriptView>` to a `Node<LayoutView>` is through a transmutation, which is
done at the moment the layout task receives nodes. (This should be factored
better to contain the unsafety.)

We should also lock down DOM node mutation to the ScriptView to forbid data
races, but this patch doesn't do that.

This also reduces coupling between DOM and layout. Soon I would like to move
the DOM into its own crate, and this is a step on the way of doing that.
…ut interface.

Eventually, the layout interface will be moved along with the DOM into a
separate crate.
Premature abstraction; nothing used the traits polymorphically. Furthermore,
they increased coupling between layout and the DOM.
@bors-servo bors-servo merged commit 0b22336 into servo:master May 30, 2013
glennw pushed a commit to glennw/servo that referenced this pull request Jan 16, 2017
Fixed a number of smoothstep() UB cases in the shaders

Fixed the red rectangle in servo#427, but the text is still broken (to be addressed later).
The change is similar to servo/webrender@b89ecd1, now all `smoothstep` calls should be correct.

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/webrender/474)
<!-- Reviewable:end -->
@jdm jdm mentioned this pull request Nov 5, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants