Pass all the data layout needs from canvas elements at once.

This commit is contained in:
Ms2ger 2015-10-26 11:43:23 +01:00
parent a5a4ef7d70
commit b1f4bf617d
4 changed files with 40 additions and 68 deletions

View file

@ -327,7 +327,8 @@ impl<'a> FlowConstructor<'a> {
}
Some(NodeTypeId::Element(ElementTypeId::HTMLElement(
HTMLElementTypeId::HTMLCanvasElement))) => {
SpecificFragmentInfo::Canvas(box CanvasFragmentInfo::new(node))
let data = node.canvas_data().unwrap();
SpecificFragmentInfo::Canvas(box CanvasFragmentInfo::new(node, data))
}
_ => {
// This includes pseudo-elements.