diff --git a/layout/generic/nsObjectFrame.cpp b/layout/generic/nsObjectFrame.cpp index be9d1a85eb90..24c494c3c098 100644 --- a/layout/generic/nsObjectFrame.cpp +++ b/layout/generic/nsObjectFrame.cpp @@ -1549,13 +1549,7 @@ nsObjectFrame::BuildLayer(nsDisplayListBuilder* aBuilder, return nsnull; } - gfxIntSize size; - - if (mInstanceOwner->UseAsyncRendering()) { - size = container->GetCurrentSize(); - } else { - size = gfxIntSize(window->width, window->height); - } + gfxIntSize size = container->GetCurrentSize(); nsRect area = GetContentRectRelativeToSelf() + aItem->ToReferenceFrame(); gfxRect r = nsLayoutUtils::RectToGfxRect(area, PresContext()->AppUnitsPerDevPixel()); @@ -1578,9 +1572,6 @@ nsObjectFrame::BuildLayer(nsDisplayListBuilder* aBuilder, ImageLayer* imglayer = static_cast(layer.get()); UpdateImageLayer(r); - if (!mInstanceOwner->UseAsyncRendering()) { - imglayer->SetScaleToSize(size, ImageLayer::SCALE_STRETCH); - } imglayer->SetContainer(container); gfxPattern::GraphicsFilter filter = nsLayoutUtils::GetGraphicsFilterForFrame(this);