sw/inc/calbck.hxx | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-)
New commits: commit 63b67ab5cab8cf7576a68cabe5fb1a42c6ad800c Author: Stephan Bergmann <[email protected]> Date: Fri Jan 8 16:39:24 2016 +0100 Use public derivation, and remove then-unnecessary downcasts ...the implicitly-private derivation was presumably introduced by accident in 23fd991fda81668b3998b21b0131dda77965e405 "separate the sane from the less sane in SwClient" Change-Id: I30ec84b6a30c029cfbeb848ad37c9a532fec0a96 diff --git a/sw/inc/calbck.hxx b/sw/inc/calbck.hxx index c80cebc..3df1f69 100644 --- a/sw/inc/calbck.hxx +++ b/sw/inc/calbck.hxx @@ -90,7 +90,7 @@ namespace sw }; } // SwClient -class SW_DLLPUBLIC SwClient : ::sw::WriterListener +class SW_DLLPUBLIC SwClient : public ::sw::WriterListener { // avoids making the details of the linked list and the callback method public friend class SwModify; @@ -297,7 +297,7 @@ public: return static_cast<TElementType*>(Sync()); while(GetRightOfPos()) m_pPosition = GetRightOfPos(); - if(dynamic_cast<const TElementType *>(static_cast<SwClient*>(m_pPosition)) != nullptr) + if(dynamic_cast<const TElementType *>(m_pPosition) != nullptr) return static_cast<TElementType*>(Sync()); return Previous(); } @@ -305,14 +305,14 @@ public: { if(!IsChanged()) m_pPosition = GetRightOfPos(); - while(m_pPosition && dynamic_cast<const TElementType *>(static_cast<SwClient*>(m_pPosition)) == nullptr) + while(m_pPosition && dynamic_cast<const TElementType *>(m_pPosition) == nullptr) m_pPosition = GetRightOfPos(); return static_cast<TElementType*>(Sync()); } TElementType* Previous() { m_pPosition = GetLeftOfPos(); - while(m_pPosition && dynamic_cast<const TElementType *>(static_cast<SwClient*>(m_pPosition)) == nullptr) + while(m_pPosition && dynamic_cast<const TElementType *>(m_pPosition) == nullptr) m_pPosition = GetLeftOfPos(); return static_cast<TElementType*>(Sync()); } _______________________________________________ Libreoffice-commits mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
