diff options
author | Jim Raykowski <raykowj@gmail.com> | 2020-07-27 17:52:41 -0800 |
---|---|---|
committer | Mike Kaganski <mike.kaganski@collabora.com> | 2020-07-30 12:03:56 +0200 |
commit | 835cd06a047717dfe5e0f117959f3c042e13b21b (patch) | |
tree | 74a334fb89d401370e9dcd51d5a3c4ad93edcc64 /sw/source/core/crsr/crstrvl.cxx | |
parent | b2686de46250d0c8d14365a2af8428387baa0c24 (diff) |
tdf#38093 Writer outline folding - outline visibility and on canvas ui
Patch 2/6
Outline content visibility and on canvas collapse/expand control button
implementations.
Change-Id: I8481125b102d2f07bfcfce91e1379d8e786a7aa2
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/99653
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
Diffstat (limited to 'sw/source/core/crsr/crstrvl.cxx')
-rw-r--r-- | sw/source/core/crsr/crstrvl.cxx | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/sw/source/core/crsr/crstrvl.cxx b/sw/source/core/crsr/crstrvl.cxx index 5ee44842b56f..5bea3f176289 100644 --- a/sw/source/core/crsr/crstrvl.cxx +++ b/sw/source/core/crsr/crstrvl.cxx @@ -1278,11 +1278,13 @@ bool SwCursorShell::GetContentAtPos( const Point& rPt, && IsAttrAtPos::Outline & rContentAtPos.eContentAtPos && !rNds.GetOutLineNds().empty() ) { - const SwTextNode* pONd = pTextNd->FindOutlineNodeOfLevel(MAXLEVEL-1, GetLayout()); - if( pONd ) + // only for nodes in outline nodes + SwOutlineNodes::size_type nPos; + if(rNds.GetOutLineNds().Seek_Entry(pTextNd, &nPos)) { rContentAtPos.eContentAtPos = IsAttrAtPos::Outline; - rContentAtPos.sStr = sw::GetExpandTextMerged(GetLayout(), *pONd, true, false, ExpandMode::ExpandFootnote); + rContentAtPos.sStr = sw::GetExpandTextMerged(GetLayout(), *pTextNd, true, false, ExpandMode::ExpandFootnote); + rContentAtPos.aFnd.pNode = pTextNd; bRet = true; } } |