Ensure unique LayerIds for pseudo-elements

Currently pseudo-elements, like the fragments created for ::before and
::after, with layers will have the same LayerId as the body of their
owning fragments. Instead all LayerIds should be unique.

Fixes #2010.
This commit is contained in:
Martin Robinson 2015-09-08 18:59:30 -07:00
parent 1b6d4daf85
commit 1e6f797268
9 changed files with 128 additions and 41 deletions

View file

@ -312,6 +312,7 @@ flaky_cpu == linebreak_simple_a.html linebreak_simple_b.html
== position_relative_vertical_percentage_overflow_a.html position_relative_vertical_percentage_overflow_ref.html
== pre_ignorable_whitespace_a.html pre_ignorable_whitespace_ref.html
== pre_with_tab.html pre_with_tab_ref.html
== pseudo_content_with_layers.html pseudo_content_with_layers_ref.html
== pseudo_element_a.html pseudo_element_b.html
== pseudo_inherit.html pseudo_inherit_ref.html
== quotes_none_a.html quotes_none_ref.html

View file

@ -0,0 +1,32 @@
<!DOCTYPE html>
<html>
<body>
<style>
.before-test::before {
content: " ";
position: fixed;
width: 100px;
height: 100px;
background: green;
}
.after-test::after {
content: " ";
position: fixed;
width: 100px;
height: 100px;
background: green;
}
div {
position: fixed;
width: 110px;
height: 110px;
background: blue;
}
</style>
<div class="before-test"> </div>
<div style="left: 150px;" class="after-test"> </div>
</body>
</html>

View file

@ -0,0 +1,18 @@
<!DOCTYPE html>
<html>
<body>
<style>
div {
position: absolute;
width: 100px;
height: 100px;
background: green;
border-right: 10px blue solid;
border-bottom: 10px blue solid;
}
</style>
<div> </div>
<div style="left: 150px;"> </div>
</body>
</html>