Bug 1209697: Part 1, Clear ancestor intrinsic sizes when our block size changes. r=dholbert
authorEmilio Cobos Álvarez <emilio@crisal.io>
Sun, 22 Jan 2017 13:57:26 +0100
changeset 469892 cfe569b9d62de94ae8ce8fd34debd37c1a26483a
parent 469891 bdc513580a45e6392816a8de4f3da0c8da5e72b0
child 469893 b4730a967e2c796fba51576da7d9e91c4ae557c8
push id43881
push userbmo:gps@mozilla.com
push dateThu, 02 Feb 2017 23:49:03 +0000
reviewersdholbert
bugs1209697
milestone54.0a1
Bug 1209697: Part 1, Clear ancestor intrinsic sizes when our block size changes. r=dholbert MozReview-Commit-ID: 9LnMm6KDcDP
layout/style/nsStyleStruct.cpp
--- a/layout/style/nsStyleStruct.cpp
+++ b/layout/style/nsStyleStruct.cpp
@@ -1587,17 +1587,18 @@ nsStylePosition::CalcDifference(const ns
     if (isVertical ? widthChanged : heightChanged) {
       // Block-size changes can affect descendant intrinsic sizes due to
       // replaced elements with percentage bsizes in descendants which
       // also have percentage bsizes. This is handled via
       // nsChangeHint_UpdateComputedBSize which clears intrinsic sizes
       // for frames that have such replaced elements.
       hint |= nsChangeHint_NeedReflow |
               nsChangeHint_UpdateComputedBSize |
-              nsChangeHint_ReflowChangesSizeOrPosition;
+              nsChangeHint_ReflowChangesSizeOrPosition |
+              nsChangeHint_ClearAncestorIntrinsics;
     }
 
     if (isVertical ? heightChanged : widthChanged) {
       // None of our inline-size differences can affect descendant
       // intrinsic sizes and none of them need to force children to
       // reflow.
       hint |= nsChangeHint_AllReflowHints &
               ~(nsChangeHint_ClearDescendantIntrinsics |