Backout bug 962791 for causing various regressions. a=lsblakk
authorBotond Ballo <botond@mozilla.com>
Fri, 31 Jan 2014 19:12:15 -0500
changeset 176177 6a87e8247640d77f4d8060f6ef3f78a80e114144
parent 176176 79f8a9a64075a7b8cfa6ad1f8b95e509d7bfd32c
child 176178 dde493494cf6e079d4611f8cb118d8641291e919
push id445
push userffxbld
push dateMon, 10 Mar 2014 22:05:19 +0000
treeherdermozilla-release@dc38b741b04e [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerslsblakk
bugs962791
milestone28.0a2
Backout bug 962791 for causing various regressions. a=lsblakk
layout/generic/nsGfxScrollFrame.cpp
--- a/layout/generic/nsGfxScrollFrame.cpp
+++ b/layout/generic/nsGfxScrollFrame.cpp
@@ -2178,27 +2178,18 @@ public:
                                   nsDisplayList* aList) {
     SetCount(++mCount);
     return new (aBuilder) nsDisplayScrollLayer(aBuilder, aList, mScrolledFrame, mScrolledFrame, mScrollFrame);
   }
 
   virtual nsDisplayItem* WrapItem(nsDisplayListBuilder* aBuilder,
                                   nsDisplayItem* aItem) {
 
-    // If the display item is for a frame that is absolutely positioned, it
-    // should only scroll with the scrolled content if its frame its contained
-    // within the scrolled content's frame.
-    bool shouldWrap = !aItem->Frame()->IsAbsolutelyPositioned() ||
-                      nsLayoutUtils::IsProperAncestorFrame(mScrolledFrame, aItem->Frame(), nullptr);
-    if (shouldWrap) {
-      SetCount(++mCount);
-      return new (aBuilder) nsDisplayScrollLayer(aBuilder, aItem, aItem->Frame(), mScrolledFrame, mScrollFrame);
-    } else {
-      return aItem;
-    }
+    SetCount(++mCount);
+    return new (aBuilder) nsDisplayScrollLayer(aBuilder, aItem, aItem->Frame(), mScrolledFrame, mScrollFrame);
   }
 
 protected:
   void SetCount(intptr_t aCount) {
     mProps.Set(nsIFrame::ScrollLayerCount(), reinterpret_cast<void*>(aCount));
   }
 
   intptr_t mCount;