summaryrefslogtreecommitdiff
path: root/sw/source/ui/misc/outline.cxx
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2021-05-18 11:44:12 +0100
committerCaolán McNamara <caolanm@redhat.com>2021-05-19 09:45:46 +0200
commit692c5df18ec1f558abe1a3a658c9881cfb7210a9 (patch)
treef9d6d6d6750ffcfa9401660314c0a1d61993766b /sw/source/ui/misc/outline.cxx
parent1815aa9472080b9dac263d393b9c922dd16351fe (diff)
ImplPlayWithRenderer never checks its OutputDevice against nullptr
just pass a reference instead and spread that around to some similar cases Change-Id: Ifb2dee8c7bf02a9f01982b928c90666cbbdd84fe Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115759 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'sw/source/ui/misc/outline.cxx')
-rw-r--r--sw/source/ui/misc/outline.cxx8
1 files changed, 4 insertions, 4 deletions
diff --git a/sw/source/ui/misc/outline.cxx b/sw/source/ui/misc/outline.cxx
index 9b65b575fbc4..69e2887c1af2 100644
--- a/sw/source/ui/misc/outline.cxx
+++ b/sw/source/ui/misc/outline.cxx
@@ -858,7 +858,7 @@ static tools::Long lcl_DrawBullet(vcl::RenderContext* pVDev, const SwNumFormat&
return nRet;
}
-static tools::Long lcl_DrawGraphic(vcl::RenderContext* pVDev, const SwNumFormat &rFormat, tools::Long nXStart, tools::Long nYStart, tools::Long nDivision)
+static tools::Long lcl_DrawGraphic(vcl::RenderContext& rVDev, const SwNumFormat &rFormat, tools::Long nXStart, tools::Long nYStart, tools::Long nDivision)
{
const SvxBrushItem* pBrushItem = rFormat.GetBrush();
tools::Long nRet = 0;
@@ -871,7 +871,7 @@ static tools::Long lcl_DrawGraphic(vcl::RenderContext* pVDev, const SwNumFormat
aGSize.setWidth( aGSize.Width() / nDivision );
nRet = aGSize.Width();
aGSize.setHeight( aGSize.Height() / nDivision );
- pGraphic->Draw(pVDev, Point(nXStart, nYStart), pVDev->PixelToLogic(aGSize));
+ pGraphic->Draw(rVDev, Point(nXStart, nYStart), rVDev.PixelToLogic(aGSize));
}
}
return nRet;
@@ -958,7 +958,7 @@ void NumberingPreview::Paint(vcl::RenderContext& rRenderContext, const tools::Re
tools::Long nBulletWidth = 0;
if (SVX_NUM_BITMAP == rFormat.GetNumberingType())
{
- nBulletWidth = lcl_DrawGraphic(pVDev.get(), rFormat, nNumberXPos,
+ nBulletWidth = lcl_DrawGraphic(*pVDev, rFormat, nNumberXPos,
nYStart, nWidthRelation);
}
else if (SVX_NUM_CHAR_SPECIAL == rFormat.GetNumberingType())
@@ -1051,7 +1051,7 @@ void NumberingPreview::Paint(vcl::RenderContext& rRenderContext, const tools::Re
tools::Long nTextOffset;
if (SVX_NUM_BITMAP == rFormat.GetNumberingType())
{
- lcl_DrawGraphic(pVDev.get(), rFormat, nXStart, nYStart, nWidthRelation);
+ lcl_DrawGraphic(*pVDev, rFormat, nXStart, nYStart, nWidthRelation);
nTextOffset = nLineHeight + nXStep;
}
else if (SVX_NUM_CHAR_SPECIAL == rFormat.GetNumberingType())