From d271ee9a31cf4af37714a68391246c8008fe86f9 Mon Sep 17 00:00:00 2001 From: Matt Woodrow Date: Fri, 18 Feb 2011 11:49:50 +1300 Subject: [PATCH] Bug 634366 - Remove broken CreateForNativePixmapSurface usage from CairoImageOGL. r=joe a=blocking2.0 --- layout/base/nsLayoutUtils.cpp | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/layout/base/nsLayoutUtils.cpp b/layout/base/nsLayoutUtils.cpp index 380dc9166d..9e318830ce 100644 --- a/layout/base/nsLayoutUtils.cpp +++ b/layout/base/nsLayoutUtils.cpp @@ -1013,10 +1013,12 @@ nsRect nsLayoutUtils::MatrixTransformRect(const nsRect &aBounds, const gfxMatrix &aMatrix, float aFactor) { - gfxRect image = aMatrix.TransformBounds(gfxRect(NSAppUnitsToFloatPixels(aBounds.x, aFactor), - NSAppUnitsToFloatPixels(aBounds.y, aFactor), - NSAppUnitsToFloatPixels(aBounds.width, aFactor), - NSAppUnitsToFloatPixels(aBounds.height, aFactor))); + nsRect outside = aBounds; + outside.ScaleRoundOut(1/aFactor); + gfxRect image = aMatrix.TransformBounds(gfxRect(outside.x, + outside.y, + outside.width, + outside.height)); return RoundGfxRectToAppRect(image, aFactor); } -- 2.11.4.GIT