[Libreoffice-commits] core.git: vcl/source
Matúš Kukan
matus.kukan at collabora.com
Thu Nov 20 03:25:33 PST 2014
vcl/source/gdi/bitmap.cxx | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
New commits:
commit e24bd9abb27801ea8e6d2d275aa23060ae798012
Author: Matúš Kukan <matus.kukan at collabora.com>
Date: Tue Nov 18 22:28:19 2014 +0100
Bitmap::Crop: When the rectangle is entire bitmap, do nothing
It is expensive to rewrite the whole bitmap with the same content.
Change-Id: I001210840d535ac54837fff092c90835f9f2f547
diff --git a/vcl/source/gdi/bitmap.cxx b/vcl/source/gdi/bitmap.cxx
index ccd914d..c034b27 100644
--- a/vcl/source/gdi/bitmap.cxx
+++ b/vcl/source/gdi/bitmap.cxx
@@ -784,7 +784,7 @@ bool Bitmap::Crop( const Rectangle& rRectPixel )
aRect.Intersection( Rectangle( Point(), aSizePix ) );
- if( !aRect.IsEmpty() )
+ if( !aRect.IsEmpty() && aSizePix != aRect.GetSize())
{
BitmapReadAccess* pReadAcc = AcquireReadAccess();
More information about the Libreoffice-commits
mailing list