| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
| |
|
|
|
|
|
|
|
|
| |
This ensures that we can pass a node address as part of the asynchronous
transition end notification, making it safe to fire the corresponding
DOM event on the node from the script thread. Without explicitly rooting
this node when the transition starts, we risk the node being GCed before
the transition is complete.
|
|
|
|
|
|
|
|
|
|
|
| |
This slims down SharedStyleContext, in preparation for a few things.
First, I would like to eventually move the stylist to the document in Servo, in
order for it to hold the StyleSheetSet.
Also, this gets rid of a fair amount of overhead while creating it in stylo.
Fixes bug 1363245.
|
|
|
|
| |
MozReview-Commit-ID: flF0fv9E9M
|
|\
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Use FunctionKeyword for computed_value of timing function
<!-- Please describe your changes on the following line: -->
https://bugzilla.mozilla.org/show_bug.cgi?id=1358330
---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `__` with appropriate data: -->
- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
- [X] These changes fix #15086
<!-- Either: -->
- [X] These changes do not require tests because mozilla-central has test cases. There might be some test cases in servo tree.
<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/16640)
<!-- Reviewable:end -->
|
| | |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Text style is always resolved via ServoStyleSet::ResolveStyleForText, either
from the frame constructor initially, or from
ServoRestyleManager::ProcessPostTraversalForText.
So text-only adjustments should go there instead. Since that doesn't call into
cascade(), all the code that passes `pseudo` there is dead code we can remove.
MozReview-Commit-ID: jpbBYpLlUL
Signed-off-by: Emilio Cobos Álvarez <emilio@crisal.io>
|
|\ \
| |/
|/|
| |
| |
| |
| |
| |
| |
| |
| | |
Implement unitless length quirk
The Gecko side doesn't propagate its quirks mode yet.
<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/16609)
<!-- Reviewable:end -->
|
| |
| |
| |
| | |
The quirks mode is still not properly propagated in geckolib.
|
| |
| |
| |
| |
| |
| |
| |
| | |
Ports the Gecko fixup for text-combine-upright writing mode to Servo. In
addition, this passes the current pseudo element (if any) down to the cascade
for use during the fixup process.
MozReview-Commit-ID: BkHd4AvSsOt
|
| | |
|
|/ |
|
|
|
|
|
|
|
|
|
| |
1. We add a new arm to TransitionProperty, TransitionProperty::Unsupported,
which contains an Atom, so it's better to remove the Copy trait from
TransitionProperty.
2. TransitionProperty::Unsupported(Atom) represents any non-animatable, custom,
or unrecognized property, and we use Atom to store the ident string for
serialization.
|
| |
|
| |
|
|\
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
stylo: Bug 1353628 - Support shorthand properties for CSS Transition.
These patches add shorthand properties into TransitionProperty, so we can parse the shorthand properties properly and create transitions for them.
---
- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
- [X] These changes fix Bug 1353628
- [X] There are tests for these changes
<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/16527)
<!-- Reviewable:end -->
|
| |
| |
| |
| |
| |
| | |
Therefore, we can start transitions on shorthand properties properly.
MozReview-Commit-ID: Ev2u2tEalnK
|
|/ |
|
| |
|
|
|
|
| |
expressions.
|
| |
|
| |
|
|
|
|
|
|
|
| |
Now that cascade() gets a Device, we can use the default computed values from
there to avoid propagating that state all over the place.
Signed-off-by: Emilio Cobos Álvarez <emilio@crisal.io>
|
|
|
|
| |
Closes #15928
|
|
|
|
|
|
|
|
|
|
| |
At least until we support scrollbars properly, this size is going to be the
correct one. I've left a TODO to grab the proper one once we support it.
This allows to trivially test viewport units for now.
MozReview-Commit-ID: JdaZ6WlZ2C6
Signed-off-by: Emilio Cobos Álvarez <emilio@crisal.io>
|
| |
|
|
|
|
|
| |
MozReview-Commit-ID: KimTU2j4V4p
Signed-off-by: Emilio Cobos Álvarez <emilio@crisal.io>
|
| |
|
| |
|
|\
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
animation-iteration-count property is a number instead of integer.
<!-- Please describe your changes on the following line: -->
This is a revised PR for #14732.
@emilio?
---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `__` with appropriate data: -->
- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
<!-- Either: -->
- [X] There are tests for these changes
<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->
<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/14851)
<!-- Reviewable:end -->
|
| | |
|
|/
|
|
| |
apply_declarations(). r=bholley
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
transition is the same as the end value for a running transition per
CSS-TRANSITIONS § 3.
Besides being contrary to spec, the old behavior could cause a cascade
of CSS transitions incorrectly triggering themselves when calls to
`getComputedStyle()` were intermingled with them.
Improves performance of nytimes.com.
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
This commit itself only moves things around and adds an extra parameter to the
`apply_declarations` function to eventually handle #14079 correctly.
Probably needs a more granular API to query fonts, á la nsFontMetrics, but
that's trivial to do once this is landed.
Then we should make the font provider mandatory, and implement the missing stylo
bits.
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
RuleTreeDeclarationsIterator would yield &PropertyDeclaration
with the lifetime of the rule tree, but the reference would only
be valid as long as the iterator was holding the corresponding lock.
The lock would be released when the iterator’s `.next()` method
moves to the next rule tree node, or when the iterator is dropped.
Also change apply_declaration to not require a `Clone` iterator
(since closures unfortunately don’t implement `Clone`).
Instead have it take a callable that returns a fresh iterator.
|
|
|
|
|
|
|
|
|
|
|
|
| |
This patch introduces infrastructure for the rule tree, and constructs it.
We don't use it yet, nor have good heuristics for GC'ing it, but this should not
happen anymore once we store the rule node reference in the node.
I haven't messed up with memory orders because I want to do a try run with it,
then mess with them.
Take down the ApplicableDeclarationsCache, use the rule tree for doing the cascade.
|
| |
|
| |
|
|
|
|
|
|
|
| |
non-inheritable ones.
This works like the `modify_style_for_*` functions and will allow us to
easily migrate from them to real cascading.
|
|
|
|
| |
thread
|
| |
|
| |
|
|
|
|
| |
Make it more different from PropertyDeclarationBlock
|
|
|
|
| |
Have a single Vec instead of two. Fix #3426
|
|
|
|
| |
Nobody else uses it, and I want to make breaking changes to it.
|
|
|
|
| |
and use it for viewport units.
|
|
|
|
|
|
|
|
|
|
| |
In the Gecko case, this style source would be the style context. In the servo
case, it will be always the computed values.
We could optimise this further in the case of stylo (from three FFI calls to
one) if we use an API of the form CalcAndStore(node, new_cv). But that would
imply borrowing the data twice from Servo (we also have borrow_data_unchecked
fwiw, but...).
|