sw/inc/calbck.hxx | 45 --------------------------------------------- 1 file changed, 45 deletions(-)
New commits: commit ecf50fe71596c3edba8ce437481ab80ae1cd8935 Author: Bjoern Michaelsen <bjoern.michael...@libreoffice.org> Date: Mon May 7 23:05:30 2018 +0200 remove now obsolete SwDepend Change-Id: I511a68c2e3612714506b09b0594e96caf4d65d0b Reviewed-on: https://gerrit.libreoffice.org/53949 Tested-by: Jenkins <c...@libreoffice.org> Reviewed-by: Björn Michaelsen <bjoern.michael...@libreoffice.org> diff --git a/sw/inc/calbck.hxx b/sw/inc/calbck.hxx index 440a822b8a15..cbe45ce74b48 100644 --- a/sw/inc/calbck.hxx +++ b/sw/inc/calbck.hxx @@ -204,51 +204,6 @@ public: bool HasOnlyOneListener() { return m_pWriterListeners && m_pWriterListeners->IsLast(); } }; -// SwDepend - -/* - * Helper class for objects that need to depend on more than one SwClient - */ -class SW_DLLPUBLIC SwDepend final : public SwClient -{ - SwClient *m_pToTell; - -public: - SwDepend(SwClient *pTellHim, SwModify *pDepend) : SwClient(pDepend), m_pToTell(pTellHim) {} - SwDepend(SwDepend&) = delete; - SwDepend(SwDepend&& o) - : SwClient(std::move(o)), m_pToTell(o.m_pToTell) - { - o.m_pToTell = nullptr; - } - - /** get Client information */ - virtual bool GetInfo( SfxPoolItem& rInfo) const override - { return m_pToTell == nullptr || m_pToTell->GetInfo( rInfo ); } -private: - virtual void Modify( const SfxPoolItem* pOldValue, const SfxPoolItem *pNewValue ) override - { - SwClientNotify(*GetRegisteredIn(), sw::LegacyModifyHint(pOldValue, pNewValue)); - } - virtual void SwClientNotify( const SwModify& rModify, const SfxHint& rHint ) override - { - if (auto pLegacyHint = dynamic_cast<const sw::LegacyModifyHint*>(&rHint)) - { - if( pLegacyHint->m_pNew && pLegacyHint->m_pNew->Which() == RES_OBJECTDYING ) - { - auto pModifyChanged = CheckRegistration(pLegacyHint->m_pOld); - if(pModifyChanged) - m_pToTell->SwClientNotify(rModify, *pModifyChanged); - } - else if( m_pToTell ) - m_pToTell->ModifyNotification(pLegacyHint->m_pOld, pLegacyHint->m_pNew); - } - else if(m_pToTell) - m_pToTell->SwClientNotifyCall(rModify, rHint); - } -}; - - namespace sw { class ListenerEntry; _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits