mirror of
https://github.com/servo/servo.git
synced 2025-08-06 22:15:33 +01:00
Move the TNode::initialize_data() call from recalc_style_at to its callers.
This will allow us to make it an inherent method.
This commit is contained in:
parent
e32b2c9ddf
commit
ae5cb0ceb0
3 changed files with 16 additions and 8 deletions
|
@ -80,7 +80,14 @@ impl<'lc, 'ln> DomTraversalContext<GeckoNode<'ln>> for RecalcStyleOnly<'lc> {
|
|||
}
|
||||
}
|
||||
|
||||
fn process_preorder(&self, node: GeckoNode<'ln>) { recalc_style_at(&self.context, self.root, node); }
|
||||
fn process_preorder(&self, node: GeckoNode<'ln>) {
|
||||
// FIXME(pcwalton): Stop allocating here. Ideally this should just be done by the HTML
|
||||
// parser.
|
||||
node.initialize_data();
|
||||
|
||||
recalc_style_at(&self.context, self.root, node);
|
||||
}
|
||||
|
||||
fn process_postorder(&self, _: GeckoNode<'ln>) {}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue