Bug 1151663 - Only call GetOrMaybeCreateDisplayPort() in nsLayoutUtils::PaintFrame() if we are using containers for root scroll frames. r=tn

This commit is contained in:
Botond Ballo 2015-04-15 17:14:32 -04:00
parent 32d4f63a35
commit 133dcaf5b9

View File

@ -3025,7 +3025,8 @@ nsLayoutUtils::PaintFrame(nsRenderingContext* aRenderingContext, nsIFrame* aFram
bool usingDisplayPort = false;
nsRect displayport;
if (rootScrollFrame && !aFrame->GetParent() &&
(aFlags & (PAINT_WIDGET_LAYERS | PAINT_TO_WINDOW))) {
(aFlags & (PAINT_WIDGET_LAYERS | PAINT_TO_WINDOW)) &&
gfxPrefs::LayoutUseContainersForRootFrames()) {
nsRect displayportBase(
nsPoint(0,0),
nsLayoutUtils::CalculateCompositionSizeForFrame(rootScrollFrame));