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 #5552 - pcwalton:block-formatting-context-cleared-float…
…s, r=glennw The speculated inline-size of the preceding floats was forced to zero at the wrong time if the float was itself cleared, causing it to overwrite the speculated value. Shuffling the code around a bit fixes the problem. r? @glennw
- Loading branch information
Showing
4 changed files
with
67 additions
and
10 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
<!DOCTYPE html> | ||
<html> | ||
<head> | ||
<!-- | ||
Tests that block formatting context inline-size speculation works when the floats that impact | ||
the block formatting context are cleared. | ||
--> | ||
<style> | ||
#a { | ||
background: silver; | ||
height: 150px; | ||
width: 150px; | ||
float: right; | ||
clear: right; | ||
} | ||
#b { | ||
background: goldenrod; | ||
height: 300px; | ||
overflow: hidden; | ||
} | ||
</style> | ||
</head> | ||
<body> | ||
<div id=a></div> | ||
<div id=b></div> | ||
</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,27 @@ | ||
<!DOCTYPE html> | ||
<html> | ||
<head> | ||
<!-- | ||
Tests that block formatting context inline-size speculation works when the floats that impact | ||
the block formatting context are cleared. | ||
--> | ||
<style> | ||
#a { | ||
background: silver; | ||
height: 150px; | ||
width: 150px; | ||
float: right; | ||
} | ||
#b { | ||
background: goldenrod; | ||
height: 300px; | ||
overflow: hidden; | ||
} | ||
</style> | ||
</head> | ||
<body> | ||
<div id=a></div> | ||
<div id=b></div> | ||
</body> | ||
</html> | ||
|