| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
| |
elements with `overflow: scroll` up to date, and take them into account
when doing hit testing.
Closes #11648.
|
| |
|
| |
|
|
|
|
|
|
| |
It's a pointless abstraction that propagates the obsolete chan terminology,
swaps the order in which the sender and receiver are returned, and hides a
source of panics.
|
|
|
|
| |
This fixes #11185.
|
|
|
|
| |
Use the SharedStyleContext instead.
|
|
|
|
|
|
|
|
| |
Add new compositor message to get scroll_offset;
Add new layout query for computed value of overflow-x/y;
Implement layer_id method for ThreadSafeLayoutNode;
Add new layout query for layer_id;
Implement script interface for getting scrollTop and scrollLeft, as well as relavant helper functions.
|
|
|
|
| |
The idea is to rename all style structs from Foo to ServoFoo, as described out in #10185.
|
|
|
|
|
| |
Fix error in construction of the origin_rect for
UnioningFragmentBorderBoxIterator.
|
| |
|
| |
|
|
|
|
| |
This is a followup to #10210, and a continuation of #10185.
|
| |
|
|
|
|
|
|
| |
Still need to implement the style invalidation.
Part of #9395
|
| |
|
|
|
|
|
| |
Add the scrollWidth and scrollHeight extensions to the element
interface.
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This fixes a bug where partially loaded content is displayed to the user
before it should be, usually before stylesheets have loaded. This commit
supresses reflows until either FirstLoad or RefreshTick, whichever comes
first.
Unfortunately, hit_test and mouse_over did not do reflows if they were
necessary, and so by suppressing the initial spurious reflows, these
methods started to panic without a display list to query. This patch
also transforms these into queries similar to the other existing
queries.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Now we only query for the topmost node, and apply the hover state to all
of the parent elements.
This fixes things like #9705, where the hover state was applied only to
the children.
This also makes us more conformant with other browsers in the case of
taking in account margins and paddings.
For example, prior to this PR, when your mouse was over the inner
element, in the bottom part, `hover` styles didn't apply to the parent.
```html
<style>
div {
padding: 10px;
margin: 10px;
height: 15px;
background: blue;
}
div:hover {
background: red;
}
</style>
<div>
<div></div>
</div>
```
Fixes #9705
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Instead of producing a tree of stacking contexts, display list
generation now produces a flat list of display items and a tree of
stacking contexts. This will eventually allow display list construction
to produce and modify WebRender vertex buffers directly, removing the
overhead of display list conversion. This change also moves
layerization of the display list to the paint thread, since it isn't
currently useful for WebRender.
To accomplish this, display list generation now takes three passes of
the flow tree:
1. Calculation of absolute positions.
2. Collection of a tree of stacking contexts.
3. Creation of a list of display items.
After collection of display items, they are sorted based upon the index
of their parent stacking contexts and their position in CSS 2.1
Appendeix E stacking order.
This is a big change, but it actually simplifies display list generation.
|
| |
|
| |
|
| |
|
|
|
|
|
| |
This commits updates rust-selectors to use the generic parser, and as
such it moves the element state into the style crate.
|
| |
|
| |
|
|\
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Split layout wrappers into style+layout and layout-only functionality
This is a step towards removing the dependency of stylo on layout/.
This PR depends on #9004.
<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9051)
<!-- Reviewable:end -->
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This patch does a number of things, unfortunately all at once:
* Hoists a large subset of the layout wrapper functionality into the style system.
* Merges TElementAttributes into the newly-created TElement.
* Reorganizes LayoutData by style vs layout, and removes LayoutDataShared.
* Simplifies the API for borrowing style/layout data.
There's still more to do to make the style system usable standalone, but
this is a good start.
|
|/ |
|
| |
|
| |
|
|
|
|
|
|
|
| |
There wasn't a good way to split this up, unfortunately.
With this change, the only remaining usage of the Servo-specific structures is
in layout_task, where the root node is received from the script task. \o/
|
|
|
|
|
|
|
|
|
|
|
| |
Updated string_cache, html5ever, xml5ever and selectors in Cargo.toml files and Cargo.lock.
Removed references to string_cache_plugin.
Import atom! and ns! from string_cache.
Replaced ns!("") by ns!().
Replaced ns!(XML) and co by ns!(xml) and co.
Replaced atom!(foo) by atom!("foo").
Replaced Atom::from_slice by Atom::from.
Replaced atom.as_slice() by &*atom.
|
|\
| |
| |
| |
| |
| |
| |
| | |
Use associated types for layout wrapper trait, and generalized ThreadSafeLayoutFoo
<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/8639)
<!-- Reviewable:end -->
|
| |
| |
| |
| | |
TThreadSafeLayoutFoo to ThreadSafeLayoutFoo.
|
| | |
|
|\ \
| |/
|/|
| |
| |
| |
| |
| |
| |
| | |
making internal pub enums, functions, and structs private
Refactoring to fix #8620
<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/8642)
<!-- Reviewable:end -->
|
| | |
|
|/
|
|
|
|
| |
This means we only deal with TrustedNodeAddress in LayoutTask::handle_reflow,
which is where the safety of this usage is guaranteed (by the ScriptReflow
destructor).
|
| |
|
| |
|
|
|
|
|
| |
I don't think this code is called when there is no document element, but I
added assertions to make sure we notice in case I was wrong.
|
| |
|
| |
|