Bug 1022612. Part 28: Make nsLayoutUtils::GetScrollableFrameFor return null for non-scrolled-frames. r=mattwoodrow

--HG--
extra : rebase_source : b93ce3cc94029fb6b8de51d5fc945d552a75a937
This commit is contained in:
Robert O'Callahan 2014-07-09 10:12:41 +12:00
parent 30dd0c42a3
commit dd612f9423
2 changed files with 4 additions and 4 deletions

View File

@ -1608,9 +1608,9 @@ AppUnitsPerDevPixel(nsDisplayItem* aItem)
* Because we only reduce the visible region here, we don't need to worry
* about whether CONTENT_OPAQUE is set; if layer was opaque in the old
* visible region, it will still be opaque in the new one.
* @param aLayerVisibleRegion the visible region of the layer, in the layer's
* coordinate space
* @param aRestrictToRect the rect to restrict the visible region to, in the
* @param aLayerVisibleRect if non-null, the visible rect of the layer, in
* the layer's coordinate space
* @param aOuterVisibleRect the rect to restrict the visible region to, in the
* parent's coordinate system
*/
static void

View File

@ -1483,7 +1483,7 @@ nsLayoutUtils::GetScrollableFrameFor(const nsIFrame *aScrolledFrame)
{
nsIFrame *frame = aScrolledFrame->GetParent();
nsIScrollableFrame *sf = do_QueryFrame(frame);
return sf;
return sf && sf->GetScrolledFrame() == aScrolledFrame ? sf : nullptr;
}
/* static */ void