From 2dbd02b576f28224204ac962f6ce20fde6687093 Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Fri, 16 Nov 2018 10:41:03 +0200 Subject: loplugin:redundantfcast improvements check for calls to constructors, and extend the list of types we check for unnecessary temporary creation Change-Id: Ia2c1f202b41ed6866779fff5343c821128033eec Reviewed-on: https://gerrit.libreoffice.org/63472 Tested-by: Jenkins Reviewed-by: Noel Grandin --- canvas/source/vcl/canvashelper.cxx | 2 +- canvas/source/vcl/spritehelper.cxx | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'canvas') diff --git a/canvas/source/vcl/canvashelper.cxx b/canvas/source/vcl/canvashelper.cxx index cdbf15cd6b88..282af010aa96 100644 --- a/canvas/source/vcl/canvashelper.cxx +++ b/canvas/source/vcl/canvashelper.cxx @@ -907,7 +907,7 @@ namespace vclcanvas beFast ? BmpScaleFlag::Default : BmpScaleFlag::BestQuality ); return uno::Reference< rendering::XBitmap >( - new CanvasBitmap( BitmapEx(aBitmap), *mpDevice, mpOutDevProvider ) ); + new CanvasBitmap( aBitmap, *mpDevice, mpOutDevProvider ) ); } uno::Sequence< sal_Int8 > CanvasHelper::getData( rendering::IntegerBitmapLayout& rLayout, diff --git a/canvas/source/vcl/spritehelper.cxx b/canvas/source/vcl/spritehelper.cxx index 123a6b64b2e4..0fa11f3dd36a 100644 --- a/canvas/source/vcl/spritehelper.cxx +++ b/canvas/source/vcl/spritehelper.cxx @@ -141,7 +141,7 @@ namespace vclcanvas // opaque. Note: since we retrieved aBmp directly // from an OutDev, it's already a 'display bitmap' // on windows. - maContent = BitmapEx( aBmp ); + maContent = aBmp; } else { -- cgit