diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2018-09-21 14:26:56 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2018-09-21 18:44:29 +0200 |
commit | 4c945b22fc42eb7a52864018cbca88358e71fd4d (patch) | |
tree | 582dad7232dcd43e00029f5573f9896a93c71ca8 /vcl | |
parent | 893f2128ed451120e41dba1ee4c2f512ec6bb20e (diff) |
new loplugin:methodcycles
look for closed cycles of methods i.e. unused code that would not
otherwise be found by the unusedmethods loplugin
Change-Id: I3fb052132d97aabca573bb8e9fc424201b1e2042
Reviewed-on: https://gerrit.libreoffice.org/60875
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'vcl')
-rw-r--r-- | vcl/source/outdev/pixel.cxx | 67 |
1 files changed, 0 insertions, 67 deletions
diff --git a/vcl/source/outdev/pixel.cxx b/vcl/source/outdev/pixel.cxx index 270a50bf6710..b00835fe96db 100644 --- a/vcl/source/outdev/pixel.cxx +++ b/vcl/source/outdev/pixel.cxx @@ -110,71 +110,4 @@ void OutputDevice::DrawPixel( const Point& rPt, const Color& rColor ) mpAlphaVDev->DrawPixel( rPt ); } -void OutputDevice::DrawPixel( const tools::Polygon& rPts, const Color* pColors ) -{ - assert(!is_double_buffered_window()); - - if ( !pColors ) - { - DrawPixel( rPts, GetLineColor() ); - } - else - { - SAL_WARN_IF( !pColors, "vcl", "OutputDevice::DrawPixel: No color array specified" ); - - const sal_uInt16 nSize = rPts.GetSize(); - - if ( nSize ) - { - if ( mpMetaFile ) - { - for ( sal_uInt16 i = 0; i < nSize; i++ ) - { - mpMetaFile->AddAction( new MetaPixelAction( rPts[ i ], pColors[ i ] ) ); - } - } - if ( !IsDeviceOutputNecessary() || ImplIsRecordLayout() ) - return; - - if ( mpGraphics || AcquireGraphics() ) - { - if ( mbInitClipRegion ) - InitClipRegion(); - - if ( mbOutputClipped ) - return; - - for ( sal_uInt16 i = 0; i < nSize; i++ ) - { - const Point aPt( ImplLogicToDevicePixel( rPts[ i ] ) ); - mpGraphics->DrawPixel( aPt.X(), aPt.Y(), pColors[ i ], this ); - } - } - } - } - - if( mpAlphaVDev ) - mpAlphaVDev->DrawPixel( rPts, pColors ); -} - -void OutputDevice::DrawPixel( const tools::Polygon& rPts, const Color& rColor ) -{ - assert(!is_double_buffered_window()); - - if( rColor != COL_TRANSPARENT && ! ImplIsRecordLayout() ) - { - const sal_uInt16 nSize = rPts.GetSize(); - std::unique_ptr<Color[]> pColArray(new Color[ nSize ]); - - for( sal_uInt16 i = 0; i < nSize; i++ ) - { - pColArray[ i ] = rColor; - } - DrawPixel( rPts, pColArray.get() ); - } - - if( mpAlphaVDev ) - mpAlphaVDev->DrawPixel( rPts, rColor ); -} - /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ |