diff options
author | Bjoern Michaelsen <bjoern.michaelsen@libreoffice.org> | 2018-05-04 08:44:47 +0200 |
---|---|---|
committer | Björn Michaelsen <bjoern.michaelsen@libreoffice.org> | 2018-05-05 08:14:12 +0200 |
commit | 83243003b46dfb258c2b41049b0e1cb82a2d7ddb (patch) | |
tree | 1e9f4fa59e10e7c8ea30fce1bd5c0cb7c37f87cd /sw/inc | |
parent | 0b56585cfc047decf25c648d3cccfc3c7b594a86 (diff) |
use WriterMultiListener instead of SwDepend in SwContentNode
- also move SwContentNode and SwTextNode from
Modify to SwClientNotify
- this removes the last public use of SwDepend, which should now become
an implementation detail of WriterMultiListener
Change-Id: I5ae3a7a091fb2b6bb3bce44a0adc4f41f07a0c30
Reviewed-on: https://gerrit.libreoffice.org/53835
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Björn Michaelsen <bjoern.michaelsen@libreoffice.org>
Diffstat (limited to 'sw/inc')
-rw-r--r-- | sw/inc/ndtxt.hxx | 1 | ||||
-rw-r--r-- | sw/inc/node.hxx | 15 |
2 files changed, 7 insertions, 9 deletions
diff --git a/sw/inc/ndtxt.hxx b/sw/inc/ndtxt.hxx index 269e66ed7516..56fbc4189371 100644 --- a/sw/inc/ndtxt.hxx +++ b/sw/inc/ndtxt.hxx @@ -198,7 +198,6 @@ public: protected: /// for hanging TextFormatCollections somewhere else (Outline-Numbering!) - virtual void Modify( const SfxPoolItem*, const SfxPoolItem* ) override; virtual void SwClientNotify( const SwModify&, const SfxHint& ) override; public: diff --git a/sw/inc/node.hxx b/sw/inc/node.hxx index 27078a918be4..1862bdf64d64 100644 --- a/sw/inc/node.hxx +++ b/sw/inc/node.hxx @@ -349,9 +349,8 @@ private: class SW_DLLPUBLIC SwContentNode: public SwModify, public SwNode, public SwIndexReg { -//FEATURE::CONDCOLL - std::unique_ptr<SwDepend> m_pCondColl; -//FEATURE::CONDCOLL + sw::WriterMultiListener m_aCondCollListener; + SwFormatColl* m_pCondColl; mutable bool mbSetModifyAtAttr; protected: @@ -372,7 +371,7 @@ protected: SwAttrSet (handle): */ sal_uInt16 ClearItemsFromAttrSet( const std::vector<sal_uInt16>& rWhichIds ); - virtual void Modify( const SfxPoolItem* pOld, const SfxPoolItem *pNew) override; + virtual void SwClientNotify( const SwModify&, const SfxHint& rHint) override; public: @@ -708,14 +707,14 @@ inline const SwDoc* SwNode::GetDoc() const inline SwFormatColl* SwContentNode::GetCondFormatColl() const { - return m_pCondColl ? static_cast<SwFormatColl*>(m_pCondColl->GetRegisteredIn()) : nullptr; + return m_pCondColl; } inline SwFormatColl& SwContentNode::GetAnyFormatColl() const { - return m_pCondColl && m_pCondColl->GetRegisteredIn() - ? *static_cast<SwFormatColl*>(m_pCondColl->GetRegisteredIn()) - : *const_cast<SwFormatColl*>(static_cast<const SwFormatColl*>(GetRegisteredIn())); + return m_pCondColl + ? *m_pCondColl + : *const_cast<SwFormatColl*>(static_cast<const SwFormatColl*>(GetRegisteredIn())); } inline const SwAttrSet& SwContentNode::GetSwAttrSet() const |