servo: Merge #8524 - Draw layers that are under sub-displaylists (from notriddle:paint_task_deep); r=jdm

Fixes #8325

Source-Repo: https://github.com/servo/servo
Source-Revision: 8f2a3a64f141f175e417e240766f9d7f06be0482
This commit is contained in:
Michael Howell 2015-11-14 21:57:22 +05:01
Родитель 1afe4ec030
Коммит 2591ecef99
1 изменённых файлов: 32 добавлений и 9 удалений

Просмотреть файл

@ -474,15 +474,38 @@ impl<C> PaintTask<C> where C: PaintListener + Send + 'static {
perspective,
parent_id));
if let PaintLayerContents::StackingContext(ref context) = paint_layer.contents {
// When there is a new layer, the transforms and origin are handled by the compositor,
// so the new transform and perspective matrices are just the identity.
continue_walking_stacking_context(properties,
&context,
&paint_layer.origin_for_child_layers(),
&Matrix4::identity(),
&Matrix4::identity(),
Some(paint_layer.id));
match paint_layer.contents {
PaintLayerContents::StackingContext(ref context) => {
// When there is a new layer, the transforms and origin are handled by the compositor,
// so the new transform and perspective matrices are just the identity.
continue_walking_stacking_context(properties,
&context,
&paint_layer.origin_for_child_layers(),
&Matrix4::identity(),
&Matrix4::identity(),
Some(paint_layer.id));
},
PaintLayerContents::DisplayList(ref display_list) => {
for kid in display_list.positioned_content.iter() {
if let &DisplayItem::StackingContextClass(ref stacking_context) = kid {
build_from_stacking_context(properties,
&stacking_context,
&parent_origin,
&transform,
&perspective,
parent_id)
}
}
for kid in display_list.layered_children.iter() {
build_from_paint_layer(properties,
&kid,
&parent_origin,
&transform,
&perspective,
parent_id)
}
},
}
}