summaryrefslogtreecommitdiff
path: root/sw/source/core/doc
diff options
context:
space:
mode:
authorMichael Stahl <Michael.Stahl@cib.de>2018-10-26 11:29:16 +0200
committerMichael Stahl <Michael.Stahl@cib.de>2018-11-10 19:47:00 +0100
commitf611e051039f489c2151d4c29af5d6eb8beb0820 (patch)
tree1d46c38ac61944be7a00de026a821ca1bccac869 /sw/source/core/doc
parentd6d76a89898cdb4b448d97daed3e3f0fb8b47fb9 (diff)
sw_redlinehide_3: adapt SwEditShell callers of SwDoc::GetNumRuleAtPos
Change-Id: I192a9743300a77bc463319789064abd89d046b0a
Diffstat (limited to 'sw/source/core/doc')
-rw-r--r--sw/source/core/doc/docnum.cxx9
1 files changed, 8 insertions, 1 deletions
diff --git a/sw/source/core/doc/docnum.cxx b/sw/source/core/doc/docnum.cxx
index e1cf7ee67c98..b3e37b23427f 100644
--- a/sw/source/core/doc/docnum.cxx
+++ b/sw/source/core/doc/docnum.cxx
@@ -2091,13 +2091,20 @@ bool SwDoc::NumOrNoNum( const SwNodeIndex& rIdx, bool bDel )
return bResult;
}
-SwNumRule* SwDoc::GetNumRuleAtPos( const SwPosition& rPos )
+SwNumRule* SwDoc::GetNumRuleAtPos(SwPosition& rPos,
+ SwRootFrame const*const pLayout)
{
SwNumRule* pRet = nullptr;
SwTextNode* pTNd = rPos.nNode.GetNode().GetTextNode();
if ( pTNd != nullptr )
{
+ if (pLayout && !sw::IsParaPropsNode(*pLayout, *pTNd))
+ {
+ pTNd = static_cast<SwTextFrame*>(pTNd->getLayoutFrame(pLayout))->GetMergedPara()->pParaPropsNode;
+ rPos.nNode = *pTNd;
+ rPos.nContent.Assign(pTNd, 0);
+ }
pRet = pTNd->GetNumRule();
}