mirror of
https://github.com/servo/servo.git
synced 2025-08-06 06:00:15 +01:00
layout: Implement z-index
.
This commit is contained in:
parent
eff0de0ce1
commit
01c90d8d6a
9 changed files with 81 additions and 18 deletions
|
@ -1239,11 +1239,10 @@ impl BlockFlow {
|
|||
if !self.base.absolute_position_info.layers_needed_for_positioned_flows &&
|
||||
!self.base.flags.needs_layer() {
|
||||
// We didn't need a layer.
|
||||
//
|
||||
// TODO(#781, pcwalton): `z-index`.
|
||||
self.base.display_list =
|
||||
mem::replace(&mut self.base.display_list,
|
||||
DisplayList::new()).flatten(PositionedDescendantStackingLevel(0));
|
||||
let z_index = self.fragment.style().get_box().z_index.number_or_zero();
|
||||
let level = PositionedDescendantStackingLevel(z_index);
|
||||
self.base.display_list = mem::replace(&mut self.base.display_list,
|
||||
DisplayList::new()).flatten(level);
|
||||
return
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue