summaryrefslogtreecommitdiff
path: root/svx/source/dialog/_contdlg.cxx
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2019-07-04 14:26:41 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2019-07-05 08:46:36 +0200
commit7f4fe205c4b1baf01115a9e0d74655818d03ec40 (patch)
treef5aead6ec8b31203aeaf8b1c68e2ff736dcd97ea /svx/source/dialog/_contdlg.cxx
parent849b837d1a3b185a8dd893a8f6eaed53605bcab1 (diff)
move the contour-finding code inside vcl
Change-Id: Iac52b72831868a917fc445e970edabc1c2585b55 Reviewed-on: https://gerrit.libreoffice.org/75080 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'svx/source/dialog/_contdlg.cxx')
-rw-r--r--svx/source/dialog/_contdlg.cxx9
1 files changed, 5 insertions, 4 deletions
diff --git a/svx/source/dialog/_contdlg.cxx b/svx/source/dialog/_contdlg.cxx
index 2832eece6ec2..cc7da3c25fd6 100644
--- a/svx/source/dialog/_contdlg.cxx
+++ b/svx/source/dialog/_contdlg.cxx
@@ -86,7 +86,8 @@ tools::PolyPolygon SvxContourDlg::CreateAutoContour( const Graphic& rGraphic,
const tools::Rectangle* pRect )
{
Bitmap aBmp;
- XOutFlags nContourFlags = XOutFlags::ContourHorz;
+ bool bContourEdgeDetect = false;
+ bool bContourVert = false;
if ( rGraphic.GetType() == GraphicType::Bitmap )
{
@@ -125,7 +126,7 @@ tools::PolyPolygon SvxContourDlg::CreateAutoContour( const Graphic& rGraphic,
else
{
aBmp = rGraphic.GetBitmapEx().GetBitmap();
- nContourFlags |= XOutFlags::ContourEdgeDetect;
+ bContourEdgeDetect = true;
}
}
else if( rGraphic.GetType() != GraphicType::NONE )
@@ -157,13 +158,13 @@ tools::PolyPolygon SvxContourDlg::CreateAutoContour( const Graphic& rGraphic,
aBmp = pVDev->GetBitmap( aPt, aSizePix );
}
- nContourFlags |= XOutFlags::ContourEdgeDetect;
+ bContourEdgeDetect = true;
}
aBmp.SetPrefSize( rGraphic.GetPrefSize() );
aBmp.SetPrefMapMode( rGraphic.GetPrefMapMode() );
- return tools::PolyPolygon( XOutBitmap::GetContour( aBmp, nContourFlags, pRect ) );
+ return tools::PolyPolygon( BitmapEx(aBmp).GetContour( bContourEdgeDetect, bContourVert, pRect ) );
}
// Loop through to super class, no virtual Methods to not become incompatible