mirror of
https://github.com/servo/servo.git
synced 2025-08-06 14:10:11 +01:00
style: Massage the resolver code so it's cleaner and prevents the problem.
This way all the borrows stay in the sharing code, and prevents an extra borrow on a cache hit, which is not a big deal but nice.
This commit is contained in:
parent
36fed07b1c
commit
891bc7d174
6 changed files with 119 additions and 119 deletions
|
@ -158,7 +158,7 @@ trait PrivateMatchMethods: TElement {
|
|||
StyleResolverForElement::new(*self, context, RuleInclusion::All, PseudoElementResolution::IfApplicable)
|
||||
.cascade_style_and_visited_with_default_parents(inputs);
|
||||
|
||||
Some(style.into())
|
||||
Some(style.0)
|
||||
}
|
||||
|
||||
#[cfg(feature = "gecko")]
|
||||
|
@ -542,7 +542,7 @@ pub trait MatchMethods : TElement {
|
|||
self.process_animations(
|
||||
context,
|
||||
&mut data.styles.primary,
|
||||
&mut new_styles.primary.0.style,
|
||||
&mut new_styles.primary.style.0,
|
||||
data.hint,
|
||||
important_rules_changed,
|
||||
);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue