tdf#114724 fix headings outline tracking highlight in Navigator

Change-Id: I7fac3c4a0f2d81c4decf59f707d1cb4d764e3e41
Reviewed-on: https://gerrit.libreoffice.org/47152
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
diff --git a/sw/source/uibase/utlui/content.cxx b/sw/source/uibase/utlui/content.cxx
index c28a8b9..6f1e71e 100644
--- a/sw/source/uibase/utlui/content.cxx
+++ b/sw/source/uibase/utlui/content.cxx
@@ -2082,6 +2082,7 @@ bool SwContentTree::HasContentChanged()
            const SwOutlineNodes::size_type nActPos = GetWrtShell()->GetOutlinePos(MAXLEVEL);
            SvTreeListEntry* pFirstEntry = First();

            SelectAll(false);
            while( nullptr != (pFirstEntry = Next(pFirstEntry)) )
            {
                assert(dynamic_cast<SwOutlineContent*>(static_cast<SwTypeNumber*>(pFirstEntry->GetUserData())));