Skip to content

Commit

Permalink
Bug 1209994. Take block-wrapper path only for blocks that are wrapper…
Browse files Browse the repository at this point in the history
…s. r=bz

--HG--
extra : commitid : BUBPKQYEZGy
extra : rebase_source : b949adb895716866f545e00dbf88734fd0138fd1
  • Loading branch information
rocallahan committed Oct 21, 2015
1 parent 95adec5 commit add8103
Show file tree
Hide file tree
Showing 10 changed files with 157 additions and 1 deletion.
2 changes: 1 addition & 1 deletion layout/generic/nsHTMLReflowState.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -619,7 +619,7 @@ nsHTMLReflowState::InitResizeFlags(nsPresContext* aPresContext, nsIAtom* aFrameT
// mCBReflowState->IsBResize() is set correctly below when
// reflowing descendant.
SetBResize(true);
} else if (mCBReflowState && !nsLayoutUtils::IsNonWrapperBlock(frame)) {
} else if (mCBReflowState && frame->IsBlockWrapper()) {
// XXX Is this problematic for relatively positioned inlines acting
// as containing block for absolutely positioned elements?
// Possibly; in that case we should at least be checking
Expand Down
17 changes: 17 additions & 0 deletions layout/reftests/bugs/1209994-1-ref.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
<!DOCTYPE html>
<style>
div {
height: 240px;
}
#f {
height: auto;
overflow: hidden;
padding: 0;
border: none;
}
</style>
There should be a visible fieldset below:
<div>
<fieldset id="f">This is fieldset</fieldset>
</div>

21 changes: 21 additions & 0 deletions layout/reftests/bugs/1209994-1.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
<!DOCTYPE html>
<style>
div {
height: 240px;
}
#f {
height: 0;
overflow: hidden;
padding: 0;
border: none;
}
</style>
There should be a visible fieldset below:
<div>
<fieldset id="f">This is fieldset</fieldset>
</div>
<script>
h = document.body.clientHeight;
f.style.height = "auto";
</script>

17 changes: 17 additions & 0 deletions layout/reftests/bugs/1209994-2-ref.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
<!DOCTYPE html>
<style>
div {
height: 240px;
}
#f {
height: auto;
overflow: hidden;
padding: 0;
border: none;
}
</style>
There should be a visible button below:
<div>
<button id="f">This is button</button>
</div>

21 changes: 21 additions & 0 deletions layout/reftests/bugs/1209994-2.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
<!DOCTYPE html>
<style>
div {
height: 240px;
}
#f {
height: 0;
overflow: hidden;
padding: 0;
border: none;
}
</style>
There should be a visible button below:
<div>
<button id="f">This is button</button>
</div>
<script>
h = document.body.clientHeight;
f.style.height = "auto";
</script>

17 changes: 17 additions & 0 deletions layout/reftests/bugs/1209994-3-ref.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
<!DOCTYPE html>
<style>
div {
height: 240px;
}
#f {
height: auto;
overflow: hidden;
padding: 0;
border: none;
}
</style>
There should be a visible table below:
<div>
<table id="f">This is a table</table>
</div>

21 changes: 21 additions & 0 deletions layout/reftests/bugs/1209994-3.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
<!DOCTYPE html>
<style>
div {
height: 240px;
}
#f {
height: 0;
overflow: hidden;
padding: 0;
border: none;
}
</style>
There should be a visible table below:
<div>
<table id="f">This is a table</table>
</div>
<script>
h = document.body.clientHeight;
f.style.height = "auto";
</script>

17 changes: 17 additions & 0 deletions layout/reftests/bugs/1209994-4-ref.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
<!DOCTYPE html>
<style>
div {
height: 240px;
}
#f {
height: auto;
overflow: hidden;
padding: 0;
border: none;
}
</style>
There should be a visible select below:
<div>
<select id="f"><option>This is a select</option></select>
</div>

21 changes: 21 additions & 0 deletions layout/reftests/bugs/1209994-4.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
<!DOCTYPE html>
<style>
div {
height: 240px;
}
#f {
height: 0;
overflow: hidden;
padding: 0;
border: none;
}
</style>
There should be a visible select below:
<div>
<select id="f"><option>This is a select</option></select>
</div>
<script>
h = document.body.clientHeight;
f.style.height = "auto";
</script>

4 changes: 4 additions & 0 deletions layout/reftests/bugs/reftest.list
Original file line number Diff line number Diff line change
Expand Up @@ -1937,3 +1937,7 @@ fuzzy(1,74) fuzzy-if(gtkWidget,6,79) == 1174332-1.html 1174332-1-ref.html
== 1202512-2.html 1202512-2-ref.html
!= 1207326-1.html about:blank
== 1209603-1.html 1209603-1-ref.html
== 1209994-1.html 1209994-1-ref.html
== 1209994-2.html 1209994-2-ref.html
== 1209994-3.html 1209994-3-ref.html
== 1209994-4.html 1209994-4-ref.html

0 comments on commit add8103

Please sign in to comment.