Back out changeset 13335ded96b9 (bug 1081272) for test_page_scroll_with_fixed_pos.html bustage
authorPhil Ringnalda <philringnalda@gmail.com>
Thu, 12 Nov 2015 20:18:03 -0800
changeset 308674 5c371591bc241f6bf3fe7378162b246b2e81dff1
parent 308673 06f91b193eb70c037820bc56f72174400efdf0cc
child 308675 aa323766c0f998f1c36eb0e8ca821b828a81701d
push id7513
push useratolfsen@mozilla.com
push dateFri, 13 Nov 2015 14:03:43 +0000
bugs1081272
milestone45.0a1
backs out13335ded96b921704816cb491a38c2b45dc8f94f
Back out changeset 13335ded96b9 (bug 1081272) for test_page_scroll_with_fixed_pos.html bustage CLOSED TREE
layout/generic/nsGfxScrollFrame.cpp
layout/generic/test/page_scroll_with_fixed_pos_window.html
--- a/layout/generic/nsGfxScrollFrame.cpp
+++ b/layout/generic/nsGfxScrollFrame.cpp
@@ -3701,19 +3701,17 @@ static nsSize
 GetScrollPortSizeExcludingHeadersAndFooters(nsIFrame* aViewportFrame,
                                             const nsRect& aScrollPort)
 {
   nsTArray<TopAndBottom> list;
   nsFrameList fixedFrames = aViewportFrame->GetChildList(nsIFrame::kFixedList);
   for (nsFrameList::Enumerator iterator(fixedFrames); !iterator.AtEnd();
        iterator.Next()) {
     nsIFrame* f = iterator.get();
-    nsRect r = f->GetRectRelativeToSelf();
-    r = nsLayoutUtils::TransformFrameRectToAncestor(f, r, aViewportFrame);
-    r = r.Intersect(aScrollPort);
+    nsRect r = f->GetRect().Intersect(aScrollPort);
     if ((r.width >= aScrollPort.width / 2 ||
          r.width >= NSIntPixelsToAppUnits(800, AppUnitsPerCSSPixel())) &&
         r.height <= aScrollPort.height/3) {
       list.AppendElement(TopAndBottom(r.y, r.YMost()));
     }
   }
 
   list.Sort(TopComparator());
--- a/layout/generic/test/page_scroll_with_fixed_pos_window.html
+++ b/layout/generic/test/page_scroll_with_fixed_pos_window.html
@@ -86,29 +86,20 @@ function runTest() {
             showFixedPosElements2(false);
 
             document.getElementById("top").style.width = "400px";
             scrollDownOnePageWithContinuation(function() {
               is(document.documentElement.scrollTop, fullPageScrollDown - (10 + 13),
                  "Don't ignore elements that span more than half the viewport side");
               document.getElementById("top").style.width = "100%";
 
-              document.getElementById("top").style.top = "-40px";
-              document.getElementById("top").style.transform = "translateY(38px)";
-              scrollDownOnePageWithContinuation(function() {
-                is(document.documentElement.scrollTop,
-                   fullPageScrollDown - (10 + 13 - 40 + 38),
-                   "Account for offset and transform");
-                document.getElementById("top").style.width = "100%";
-
-                // Scroll back up so test results are visible
-                document.documentElement.scrollTop = 0;
-                SimpleTest.finish();
-                window.close();
-              });
+              // Scroll back up so test results are visible
+              document.documentElement.scrollTop = 0;
+              SimpleTest.finish();
+              window.close();
             });
           });
         });
       });
     });
   });
 }
 </script>