Kaydet (Commit) ebe714b1 authored tarafından Michael Stahl's avatar Michael Stahl

sw_redlinehide_3: filter outline nodes in SwListShell::Execute()

Change-Id: I31677211d0aa5637e0cce0034e29b9db724c791b
üst 50bd0f5f
......@@ -80,8 +80,11 @@ static void lcl_OutlineUpDownWithSubPoints( SwWrtShell& rSh, bool bMove, bool bU
{
// Move down with subpoints:
while ( nActEndPos < pIDoc->getOutlineNodesCount() &&
pIDoc->getOutlineLevel( nActEndPos ) > nActLevel )
(!pIDoc->isOutlineInLayout(nActEndPos, *rSh.GetLayout())
|| nActLevel < pIDoc->getOutlineLevel(nActEndPos)))
{
++nActEndPos;
}
if ( nActEndPos < pIDoc->getOutlineNodesCount() )
{
......@@ -90,8 +93,11 @@ static void lcl_OutlineUpDownWithSubPoints( SwWrtShell& rSh, bool bMove, bool bU
--nActEndPos;
SwOutlineNodes::size_type nDest = nActEndPos + 2;
while ( nDest < pIDoc->getOutlineNodesCount() &&
pIDoc->getOutlineLevel( nDest ) > nActLevel )
(!pIDoc->isOutlineInLayout(nDest, *rSh.GetLayout())
|| nActLevel < pIDoc->getOutlineLevel(nDest)))
{
++nDest;
}
nDir = nDest - 1 - nActEndPos;
}
......@@ -101,10 +107,14 @@ static void lcl_OutlineUpDownWithSubPoints( SwWrtShell& rSh, bool bMove, bool bU
// Move up with subpoints:
if ( nActPos > 0 )
{
--nActEndPos;
nActEndPos = nActPos;
SwOutlineNodes::size_type nDest = nActPos - 1;
while ( nDest > 0 && pIDoc->getOutlineLevel( nDest ) > nActLevel )
while (nDest > 0 &&
(!pIDoc->isOutlineInLayout(nDest, *rSh.GetLayout())
|| nActLevel < pIDoc->getOutlineLevel(nDest)))
{
--nDest;
}
nDir = nDest - nActPos;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment