summaryrefslogtreecommitdiff
path: root/sw
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2023-11-08 09:21:44 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2023-11-09 06:25:15 +0100
commit43c9c359471ed6a91bf4eff3f75dddba3ca2214c (patch)
tree808e4873111a61819af89c0487b887d2873312dc /sw
parent1564e33b861f22c0f6eac546deca5300d5d7b56f (diff)
loplugin:fieldcast in Num_Info
Change-Id: I9d839c22579e5bc5fe6250a8aab0285ca9e0a4c7 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/159170 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sw')
-rw-r--r--sw/inc/EnhancedPDFExportHelper.hxx5
-rw-r--r--sw/source/core/text/EnhancedPDFExportHelper.cxx4
2 files changed, 5 insertions, 4 deletions
diff --git a/sw/inc/EnhancedPDFExportHelper.hxx b/sw/inc/EnhancedPDFExportHelper.hxx
index 6b2e2655ea43..dd20f54cbef8 100644
--- a/sw/inc/EnhancedPDFExportHelper.hxx
+++ b/sw/inc/EnhancedPDFExportHelper.hxx
@@ -44,6 +44,7 @@ class SwTextNode;
class SwTable;
class SwNumberTreeNode;
class SwTextPaintInfo;
+class SwTextFrame;
/*
* Mapping of OOo elements to tagged pdf elements:
@@ -96,8 +97,8 @@ class SwTextPaintInfo;
struct Num_Info
{
- const SwFrame& mrFrame;
- Num_Info( const SwFrame& rFrame ) : mrFrame( rFrame ) {};
+ const SwTextFrame& mrFrame;
+ Num_Info( const SwTextFrame& rFrame ) : mrFrame( rFrame ) {};
};
struct Frame_Info
diff --git a/sw/source/core/text/EnhancedPDFExportHelper.cxx b/sw/source/core/text/EnhancedPDFExportHelper.cxx
index c9829e0f5ef1..2bf5ca3f883d 100644
--- a/sw/source/core/text/EnhancedPDFExportHelper.cxx
+++ b/sw/source/core/text/EnhancedPDFExportHelper.cxx
@@ -585,7 +585,7 @@ void SwTaggedPDFHelper::BeginTag( vcl::PDFWriter::StructElement eType, const OUS
if ( mpNumInfo )
{
- const SwTextFrame& rTextFrame = static_cast<const SwTextFrame&>(mpNumInfo->mrFrame);
+ const SwTextFrame& rTextFrame = mpNumInfo->mrFrame;
SwTextNode const*const pTextNd = rTextFrame.GetTextNodeForParaProps();
const SwNodeNum* pNodeNum = pTextNd->GetNum(rTextFrame.getRootFrame());
@@ -1071,7 +1071,7 @@ void SwTaggedPDFHelper::SetAttributes( vcl::PDFWriter::StructElement eType )
}
else if (mpNumInfo && eType == vcl::PDFWriter::List)
{
- SwTextFrame const& rFrame(static_cast<SwTextFrame const&>(mpNumInfo->mrFrame));
+ SwTextFrame const& rFrame(mpNumInfo->mrFrame);
SwTextNode const& rNode(*rFrame.GetTextNodeForParaProps());
SwNumRule const*const pNumRule = rNode.GetNumRule();
assert(pNumRule); // was required for List