Change overflow calculation to be calculated after compute_absolute_position.

Also include absolutely positioned elements in the overflow rect calculation.

Fixes #7797.
This commit is contained in:
Glenn Watson 2015-11-03 15:49:52 +10:00
parent 4f51710ed3
commit 695b7491fe
10 changed files with 75 additions and 105 deletions

View file

@ -15,6 +15,18 @@
"deleted": [],
"items": {
"reftest": {
"css/abs-overflow-stackingcontext.html": [
{
"path": "css/abs-overflow-stackingcontext.html",
"references": [
[
"/_mozilla/css/abs-overflow-stackingcontext_ref.html",
"=="
]
],
"url": "/_mozilla/css/abs-overflow-stackingcontext.html"
}
],
"css/abs_float_pref_width.html": [
{
"path": "css/abs_float_pref_width.html",
@ -4750,6 +4762,18 @@
}
},
"reftest_nodes": {
"css/abs-overflow-stackingcontext.html": [
{
"path": "css/abs-overflow-stackingcontext.html",
"references": [
[
"/_mozilla/css/abs-overflow-stackingcontext_ref.html",
"=="
]
],
"url": "/_mozilla/css/abs-overflow-stackingcontext.html"
}
],
"css/abs_float_pref_width.html": [
{
"path": "css/abs_float_pref_width.html",

View file

@ -0,0 +1,24 @@
<!DOCTYPE html>
<html>
<head>
<link rel='match' href='abs-overflow-stackingcontext_ref.html'>
<style>
html, body {
margin: 0;
perspective: 1000px;
}
div {
position: absolute;
top: 25vh;
left: 25vw;
width: 50vw;
height: 50vh;
background-color: green;
}
</style>
</head>
<body>
<div></div>
</body>
</html>

View file

@ -0,0 +1,22 @@
<!DOCTYPE html>
<html>
<head>
<style>
html, body {
margin: 0;
}
div {
position: absolute;
top: 25vh;
left: 25vw;
width: 50vw;
height: 50vh;
background-color: green;
}
</style>
</head>
<body>
<div></div>
</body>
</html>