diff options
-rw-r--r-- | sw/source/core/crsr/bookmrk.cxx | 18 | ||||
-rw-r--r-- | sw/source/core/doc/docbm.cxx | 5 | ||||
-rw-r--r-- | sw/source/core/inc/bookmrk.hxx | 6 |
3 files changed, 20 insertions, 9 deletions
diff --git a/sw/source/core/crsr/bookmrk.cxx b/sw/source/core/crsr/bookmrk.cxx index 1c4d4941463a..3de0b8351391 100644 --- a/sw/source/core/crsr/bookmrk.cxx +++ b/sw/source/core/crsr/bookmrk.cxx @@ -431,6 +431,24 @@ namespace sw { namespace mark } } + void Bookmark::Hide(bool const isHide) + { + if (isHide != m_bHidden) + { + m_bHidden = isHide; + InvalidateFrames(); + } + } + + void Bookmark::SetHideCondition(OUString const& rHideCondition) + { + if (m_sHideCondition != rHideCondition) + { + m_sHideCondition = rHideCondition; + InvalidateFrames(); + } + } + ::sfx2::IXmlIdRegistry& Bookmark::GetRegistry() { SwDoc *const pDoc( GetMarkPos().GetDoc() ); diff --git a/sw/source/core/doc/docbm.cxx b/sw/source/core/doc/docbm.cxx index 13034ce3a699..7918e5db8dbe 100644 --- a/sw/source/core/doc/docbm.cxx +++ b/sw/source/core/doc/docbm.cxx @@ -561,11 +561,6 @@ namespace sw { namespace mark pPos2->nContent.GetIndex()); } #endif - // see for example _SaveContentIdx, Shells - OSL_PRECOND(m_vAllMarks.size() < USHRT_MAX, - "MarkManager::makeMark(..)" - " - more than USHRT_MAX marks are not supported correctly"); - if ( (!rPaM.GetPoint()->nNode.GetNode().IsTextNode() && (eType != MarkType::UNO_BOOKMARK // SwXTextRange can be on table node or plain start node (FLY_AT_FLY) diff --git a/sw/source/core/inc/bookmrk.hxx b/sw/source/core/inc/bookmrk.hxx index 45be76199073..fe5bff942568 100644 --- a/sw/source/core/inc/bookmrk.hxx +++ b/sw/source/core/inc/bookmrk.hxx @@ -186,10 +186,8 @@ namespace sw { { return m_bHidden; } virtual const OUString& GetHideCondition() const override { return m_sHideCondition; } - virtual void Hide(bool rHide) override - { m_bHidden = rHide; } - virtual void SetHideCondition(const OUString& rHideCondition) override - { m_sHideCondition = rHideCondition; } + virtual void Hide(bool rHide) override; + virtual void SetHideCondition(const OUString& rHideCondition) override; // ::sfx2::Metadatable virtual ::sfx2::IXmlIdRegistry& GetRegistry() override; |