diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2018-12-04 08:37:09 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2018-12-05 07:51:19 +0100 |
commit | df55a6ca81848a5a095f08ae5265186d38176d40 (patch) | |
tree | f95e72c0c885efe9f73ab38d0d82f1bba757a4bf | |
parent | 5e93e406cbada31882c33fe1f420af29039027be (diff) |
remove unused GraphicManagerDrawFlags enum
Change-Id: I12ef5e6257db337c4432b251bc92107a2c2ea88b
Reviewed-on: https://gerrit.libreoffice.org/64557
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
-rw-r--r-- | include/vcl/GraphicObject.hxx | 17 | ||||
-rw-r--r-- | sc/source/ui/view/printfun.cxx | 1 | ||||
-rw-r--r-- | sw/source/core/layout/paintfrm.cxx | 1 | ||||
-rw-r--r-- | vcl/source/graphic/GraphicObject.cxx | 4 | ||||
-rw-r--r-- | vcl/source/graphic/GraphicObject2.cxx | 16 |
5 files changed, 11 insertions, 28 deletions
diff --git a/include/vcl/GraphicObject.hxx b/include/vcl/GraphicObject.hxx index 854cc14ec6fd..9ffbd9a73ba2 100644 --- a/include/vcl/GraphicObject.hxx +++ b/include/vcl/GraphicObject.hxx @@ -27,17 +27,6 @@ namespace com { namespace sun { namespace star { namespace graphic { class XGraphic; } } } } namespace o3tl { template <typename T> struct typed_flags; } -enum class GraphicManagerDrawFlags -{ - CACHED = 0x01, - SMOOTHSCALE = 0x02, - STANDARD = CACHED | SMOOTHSCALE, -}; -namespace o3tl -{ - template<> struct typed_flags<GraphicManagerDrawFlags> : is_typed_flags<GraphicManagerDrawFlags, 0x02> {}; -} - // Adjustment defines enum class GraphicAdjustmentFlags { @@ -214,8 +203,7 @@ private: int nNumTilesX, int nNumTilesY, const Size& rTileSizePixel, - const GraphicAttr* pAttr, - GraphicManagerDrawFlags nFlags + const GraphicAttr* pAttr ); /// internally called by ImplRenderTempTile() @@ -229,7 +217,6 @@ private: int nRemainderTilesY, const Size& rTileSizePixel, const GraphicAttr* pAttr, - GraphicManagerDrawFlags nFlags, ImplTileInfo& rTileInfo ); @@ -239,7 +226,6 @@ private: const Size& rSizePixel, const Size& rOffset, const GraphicAttr* pAttr, - GraphicManagerDrawFlags nFlags, int nTileCacheSize1D ); @@ -365,7 +351,6 @@ public: const tools::Rectangle& rArea, const Size& rSize, const Size& rOffset, - GraphicManagerDrawFlags nFlags = GraphicManagerDrawFlags::STANDARD, int nTileCacheSize1D=128 ); diff --git a/sc/source/ui/view/printfun.cxx b/sc/source/ui/view/printfun.cxx index b2de8a6bf82d..e144046b7fd7 100644 --- a/sc/source/ui/view/printfun.cxx +++ b/sc/source/ui/view/printfun.cxx @@ -1229,7 +1229,6 @@ static void lcl_DrawGraphic( const SvxBrushItem &rBrush, vcl::RenderContext *pOu const double Abitmap( k1/k2 * aSize.Width()*aSize.Height() ); aObject.DrawTiled( pOut, rOrg, aGrfSize, Size(0,0), - GraphicManagerDrawFlags::STANDARD, ::std::max( 128, static_cast<int>( sqrt(sqrt( Abitmap)) + .5 ) ) ); } else diff --git a/sw/source/core/layout/paintfrm.cxx b/sw/source/core/layout/paintfrm.cxx index 57d7d95da130..020ae12a4f3d 100644 --- a/sw/source/core/layout/paintfrm.cxx +++ b/sw/source/core/layout/paintfrm.cxx @@ -1927,7 +1927,6 @@ void DrawGraphic( aAlignedPaintRect.SVRect(), aGrf.SSize(), Size( aPaintOffset.X(), aPaintOffset.Y() ), - GraphicManagerDrawFlags::STANDARD, std::max( 128, static_cast<int>( sqrt(sqrt( Abitmap)) + .5 ) ) ); } // reset clipping at output device diff --git a/vcl/source/graphic/GraphicObject.cxx b/vcl/source/graphic/GraphicObject.cxx index cbfd8a84f4d5..bcfc50c849a1 100644 --- a/vcl/source/graphic/GraphicObject.cxx +++ b/vcl/source/graphic/GraphicObject.cxx @@ -529,7 +529,7 @@ bool GraphicObject::Draw( OutputDevice* pOut, const Point& rPt, const Size& rSz, } void GraphicObject::DrawTiled( OutputDevice* pOut, const tools::Rectangle& rArea, const Size& rSize, - const Size& rOffset, GraphicManagerDrawFlags nFlags, int nTileCacheSize1D ) + const Size& rOffset, int nTileCacheSize1D ) { if( pOut == nullptr || rSize.Width() == 0 || rSize.Height() == 0 ) return; @@ -547,7 +547,7 @@ void GraphicObject::DrawTiled( OutputDevice* pOut, const tools::Rectangle& rArea while ((static_cast<sal_Int64>(rSize.Height()) * nTileCacheSize1D) > SAL_MAX_UINT16) nTileCacheSize1D /= 2; - ImplDrawTiled( pOut, rArea, aOutTileSize, rOffset, nullptr, nFlags, nTileCacheSize1D ); + ImplDrawTiled( pOut, rArea, aOutTileSize, rOffset, nullptr, nTileCacheSize1D ); } bool GraphicObject::StartAnimation( OutputDevice* pOut, const Point& rPt, const Size& rSz, diff --git a/vcl/source/graphic/GraphicObject2.cxx b/vcl/source/graphic/GraphicObject2.cxx index 644814e6e763..ac3be21a5bfa 100644 --- a/vcl/source/graphic/GraphicObject2.cxx +++ b/vcl/source/graphic/GraphicObject2.cxx @@ -67,7 +67,7 @@ struct ImplTileInfo bool GraphicObject::ImplRenderTempTile( VirtualDevice& rVDev, int nNumTilesX, int nNumTilesY, const Size& rTileSizePixel, - const GraphicAttr* pAttr, GraphicManagerDrawFlags nFlags ) + const GraphicAttr* pAttr ) { // how many tiles to generate per recursion step const int nExponent = 2; @@ -93,7 +93,7 @@ bool GraphicObject::ImplRenderTempTile( VirtualDevice& rVDev, rVDev.EnableMapMode( false ); bool bRet( ImplRenderTileRecursive( rVDev, nExponent, nMSBFactor, nNumTilesX, nNumTilesY, - nNumTilesX, nNumTilesY, rTileSizePixel, pAttr, nFlags, aTileInfo ) ); + nNumTilesX, nNumTilesY, rTileSizePixel, pAttr, aTileInfo ) ); rVDev.EnableMapMode( bOldMap ); @@ -111,7 +111,7 @@ bool GraphicObject::ImplRenderTileRecursive( VirtualDevice& rVDev, int nExponent int nNumOrigTilesX, int nNumOrigTilesY, int nRemainderTilesX, int nRemainderTilesY, const Size& rTileSizePixel, const GraphicAttr* pAttr, - GraphicManagerDrawFlags nFlags, ImplTileInfo& rTileInfo ) + ImplTileInfo& rTileInfo ) { // gets loaded with our tile bitmap std::unique_ptr<GraphicObject> xTmpGraphic; @@ -145,7 +145,7 @@ bool GraphicObject::ImplRenderTileRecursive( VirtualDevice& rVDev, int nExponent else if( ImplRenderTileRecursive( rVDev, nExponent, nMSBFactor/nExponent, nNumOrigTilesX, nNumOrigTilesY, nNewRemainderX, nNewRemainderY, - rTileSizePixel, pAttr, nFlags, aTileInfo ) ) + rTileSizePixel, pAttr, aTileInfo ) ) { // extract generated tile -> see comment on the first loop below BitmapEx aTileBitmap( rVDev.GetBitmap( aTileInfo.aTileTopLeft, aTileInfo.aTileSizePixel ) ); @@ -282,7 +282,7 @@ bool GraphicObject::ImplRenderTileRecursive( VirtualDevice& rVDev, int nExponent } bool GraphicObject::ImplDrawTiled( OutputDevice* pOut, const tools::Rectangle& rArea, const Size& rSizePixel, - const Size& rOffset, const GraphicAttr* pAttr, GraphicManagerDrawFlags nFlags, int nTileCacheSize1D ) + const Size& rOffset, const GraphicAttr* pAttr, int nTileCacheSize1D ) { const MapMode aOutMapMode( pOut->GetMapMode() ); const MapMode aMapMode( aOutMapMode.GetMapUnit(), Point(), aOutMapMode.GetScaleX(), aOutMapMode.GetScaleY() ); @@ -307,7 +307,7 @@ bool GraphicObject::ImplDrawTiled( OutputDevice* pOut, const tools::Rectangle& r // draw bitmap content if( ImplRenderTempTile( *aVDev.get(), nNumTilesInCacheX, - nNumTilesInCacheY, rSizePixel, pAttr, nFlags ) ) + nNumTilesInCacheY, rSizePixel, pAttr ) ) { BitmapEx aTileBitmap( aVDev->GetBitmap( Point(0,0), aVDev->GetOutputSize() ) ); @@ -322,7 +322,7 @@ bool GraphicObject::ImplDrawTiled( OutputDevice* pOut, const tools::Rectangle& r aAlphaGraphic.SetGraphic( GetGraphic().GetBitmapEx().GetMask() ); if( aAlphaGraphic.ImplRenderTempTile( *aVDev.get(), nNumTilesInCacheX, - nNumTilesInCacheY, rSizePixel, pAttr, nFlags ) ) + nNumTilesInCacheY, rSizePixel, pAttr ) ) { // Combine bitmap and alpha/mask if( GetGraphic().IsAlpha() ) @@ -338,7 +338,7 @@ bool GraphicObject::ImplDrawTiled( OutputDevice* pOut, const tools::Rectangle& r GraphicObject aTmpGraphic( aTileBitmap ); bRet = aTmpGraphic.ImplDrawTiled( pOut, rArea, aTileBitmap.GetSizePixel(), - rOffset, pAttr, nFlags, nTileCacheSize1D ); + rOffset, pAttr, nTileCacheSize1D ); } } else |