Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Auto merge of #17581 - mbrubeck:incremental, r=pcwalton
Fix incremental layout bugs for absolute and cleared elements Fixes #17307. <del>There were two underlying bugs:</del> * <del>Nodes were not marked dirty when their style attribute changed.</del> * BaseFlow flags set during flow construction could get out of sync with the element's style if repair_style was called. --- - [x] `./mach build -d` does not report any errors - [x] `./mach test-tidy` does not report any errors - [x] These changes fix #17307 - [x] There are tests for these changes <!-- Reviewable:start --> --- This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/17581) <!-- Reviewable:end -->
- Loading branch information
Showing
8 changed files
with
97 additions
and
6 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 0 additions & 3 deletions
3
tests/wpt/metadata-css/css21_dev/html4/dynamic-top-change-001.htm.ini
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
<!doctype html> | ||
<html class="reftest-wait"> | ||
<head> | ||
<meta charset="utf-8"> | ||
<title>Incremental absolute position test</title> | ||
<link rel="match" href="incremental_position_ref.html"> | ||
<style> | ||
#rect { | ||
position: absolute; | ||
border: 1px solid red; | ||
width: 40px; | ||
height: 40px; | ||
} | ||
</style> | ||
</head> | ||
<body> | ||
<div id="rect"></div> | ||
<script> | ||
window.onload = function() { | ||
document.body.offsetWidth; // force layout | ||
var e = document.getElementById("rect"); | ||
e.style.left = "100px"; | ||
document.documentElement.classList.remove('reftest-wait'); | ||
}; | ||
</script> | ||
</body> | ||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
<!doctype html> | ||
<html> | ||
<head> | ||
<meta charset="utf-8"> | ||
<title>Incremental absolute position reference</title> | ||
<style> | ||
#rect { | ||
position: absolute; | ||
border: 1px solid red; | ||
width: 40px; | ||
height: 40px; | ||
left: 100px; | ||
} | ||
</style> | ||
</head> | ||
<body> | ||
<div id="rect"></div> | ||
</body> | ||
</html> |