mirror of
https://github.com/servo/servo.git
synced 2025-08-06 22:15:33 +01:00
try to reset flows which need reflow, since reflow isn't yet idempotent
This commit is contained in:
parent
d168501555
commit
f552e2f750
13 changed files with 310 additions and 82 deletions
|
@ -14,6 +14,7 @@ use sync::Arc;
|
|||
/// Node mixin providing `style` method that returns a `NodeStyle`
|
||||
pub trait StyledNode {
|
||||
fn style<'a>(&'a self) -> &'a Arc<ComputedValues>;
|
||||
fn unstyle(self);
|
||||
fn restyle_damage(self) -> RestyleDamage;
|
||||
fn set_restyle_damage(self, damage: RestyleDamage);
|
||||
}
|
||||
|
@ -24,6 +25,10 @@ impl<'ln> StyledNode for ThreadSafeLayoutNode<'ln> {
|
|||
self.get_css_select_results()
|
||||
}
|
||||
|
||||
fn unstyle(self) {
|
||||
self.remove_css_select_results()
|
||||
}
|
||||
|
||||
fn restyle_damage(self) -> RestyleDamage {
|
||||
self.get_restyle_damage()
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue