Bug 1338053 - Make nsFlexContainerFrame::MarkIntrinsicISizesDirty() also call its parent class's method. r=emilio, a=lizzard
authorDaniel Holbert <dholbert@cs.stanford.edu>
Wed, 08 Feb 2017 23:08:43 -0800
changeset 378556 d5486b5487e21e05de60ef5ea8ad91a0b067d838
parent 378555 a26a6726bf710f3568d65ecb864efa478674fe58
child 378557 00ad109ba6a6999b1bb3e205cf3d1af807a4e7c1
push id1419
push userjlund@mozilla.com
push dateMon, 10 Apr 2017 20:44:07 +0000
treeherdermozilla-release@5e6801b73ef6 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersemilio, lizzard
bugs1338053
milestone53.0a2
Bug 1338053 - Make nsFlexContainerFrame::MarkIntrinsicISizesDirty() also call its parent class's method. r=emilio, a=lizzard MozReview-Commit-ID: 72oIlunLcVq
layout/generic/nsFlexContainerFrame.cpp
layout/reftests/xul/css-flex-1-ref.html
layout/reftests/xul/css-flex-1.xul
layout/reftests/xul/reftest.list
--- a/layout/generic/nsFlexContainerFrame.cpp
+++ b/layout/generic/nsFlexContainerFrame.cpp
@@ -1863,16 +1863,17 @@ nsFlexContainerFrame::MeasureAscentAndHe
 }
 
 /* virtual */ void
 nsFlexContainerFrame::MarkIntrinsicISizesDirty()
 {
   for (nsIFrame* childFrame : mFrames) {
     childFrame->Properties().Delete(CachedFlexMeasuringReflow());
   }
+  nsContainerFrame::MarkIntrinsicISizesDirty();
 }
 
 nscoord
 nsFlexContainerFrame::
   MeasureFlexItemContentHeight(nsPresContext* aPresContext,
                                FlexItem& aFlexItem,
                                bool aForceVerticalResizeForMeasuringReflow,
                                const ReflowInput& aParentReflowInput)
new file mode 100644
--- /dev/null
+++ b/layout/reftests/xul/css-flex-1-ref.html
@@ -0,0 +1,18 @@
+<!DOCTYPE html>
+<html>
+<head>
+  <style>
+    body { margin: 0 }
+    div.ref {
+      border: 1px solid black;
+      box-sizing: border-box;
+      background: green;
+      height: 50px;
+      width: 100px;
+    }
+  </style>
+</head>
+<body>
+  <div class="ref"></div>
+</body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/xul/css-flex-1.xul
@@ -0,0 +1,27 @@
+<?xml version="1.0"?>
+<window xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
+        class="reftest-wait"
+        onload="tweak()">
+  <style xmlns="http://www.w3.org/1999/xhtml">
+    <![CDATA[
+    panelview {
+      border: 1px solid black;
+      background: green;
+      display: flex;
+      height: 50px;
+    }
+    ]]>
+  </style>
+  <script>
+    <![CDATA[
+    function tweak() {
+      var tweakMe = document.getElementById("tweakMe");
+      tweakMe.style.width = "100px";
+      document.documentElement.className = "";
+    }
+    ]]>
+  </script>
+  <hbox>
+    <panelview id="tweakMe"></panelview>
+  </hbox>
+</window>
--- a/layout/reftests/xul/reftest.list
+++ b/layout/reftests/xul/reftest.list
@@ -1,8 +1,10 @@
+== css-flex-1.xul css-flex-1-ref.html
+
 == menuitem-key.xul menuitem-key-ref.xul
 # these random-if(Android) are due to differences between Android Native & Xul, see bug 732569
 random-if(Android) == menulist-shrinkwrap-1.xul menulist-shrinkwrap-1-ref.xul
 random-if(Android) fails-if(winWidget) == menulist-shrinkwrap-2.xul menulist-shrinkwrap-2-ref.xul
 == textbox-overflow-1.xul textbox-overflow-1-ref.xul # for bug 749658
 # accesskeys are not normally displayed on Mac, so skip this test
 skip-if(cocoaWidget) == accesskey.xul accesskey-ref.xul
 fails-if(cocoaWidget) fails-if(browserIsRemote&&dwrite) fuzzy-if(xulRuntime.widgetToolkit=="gtk3",1,11) == tree-row-outline-1.xul tree-row-outline-1-ref.xul # win8: bug 1254832