diff --git a/layout/base/FrameLayerBuilder.cpp b/layout/base/FrameLayerBuilder.cpp index 60b69a9578d..7432e1f7602 100644 --- a/layout/base/FrameLayerBuilder.cpp +++ b/layout/base/FrameLayerBuilder.cpp @@ -491,7 +491,7 @@ public: return aRegion.ScaleToNearestPixels(mParameters.mXScale, mParameters.mYScale, mAppUnitsPerDevPixel); } - nsIntRect ScaleToOutsidePixels(const nsRect& aRect, bool aSnap) + nsIntRect ScaleToOutsidePixels(const nsRect& aRect, bool aSnap = false) { if (aSnap && mSnappingEnabled) { return ScaleToNearestPixels(aRect); @@ -499,7 +499,7 @@ public: return aRect.ScaleToOutsidePixels(mParameters.mXScale, mParameters.mYScale, mAppUnitsPerDevPixel); } - nsIntRect ScaleToInsidePixels(const nsRect& aRect, bool aSnap) + nsIntRect ScaleToInsidePixels(const nsRect& aRect, bool aSnap = false) { if (aSnap && mSnappingEnabled) { return ScaleToNearestPixels(aRect); @@ -508,7 +508,7 @@ public: mAppUnitsPerDevPixel); } - nsIntRegion ScaleRegionToInsidePixels(const nsRegion& aRegion, bool aSnap) + nsIntRegion ScaleRegionToInsidePixels(const nsRegion& aRegion, bool aSnap = false) { if (aSnap && mSnappingEnabled) { return ScaleRegionToNearestPixels(aRegion); @@ -517,6 +517,15 @@ public: mAppUnitsPerDevPixel); } + nsIntRegion ScaleRegionToOutsidePixels(const nsRegion& aRegion, bool aSnap = false) + { + if (aSnap && mSnappingEnabled) { + return ScaleRegionToNearestPixels(aRegion); + } + return aRegion.ScaleToOutsidePixels(mParameters.mXScale, mParameters.mYScale, + mAppUnitsPerDevPixel); + } + protected: friend class ThebesLayerData;