diff options
author | Bjoern Michaelsen <bjoern.michaelsen@libreoffice.org> | 2020-09-20 12:03:42 +0200 |
---|---|---|
committer | Bjoern Michaelsen <bjoern.michaelsen@libreoffice.org> | 2020-09-27 23:03:06 +0200 |
commit | dec9a123867dcd0fea4683beeb3b4b6659f926f3 (patch) | |
tree | 445a1e1fdcb6837e48677977687989ae9bf1ca1a /sw/source/core/access | |
parent | b3fa0c06fe153737a125c9ba6f8fcc7d0a4d391d (diff) |
Move default way to find Which to an inline function
Change-Id: Ie3aa3f8a2c34c510a391d729f3dc2286f735111a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103066
Tested-by: Jenkins
Reviewed-by: Bjoern Michaelsen <bjoern.michaelsen@libreoffice.org>
Diffstat (limited to 'sw/source/core/access')
-rw-r--r-- | sw/source/core/access/accframebase.cxx | 2 | ||||
-rw-r--r-- | sw/source/core/access/accnotextframe.cxx | 2 | ||||
-rw-r--r-- | sw/source/core/access/acctable.cxx | 2 | ||||
-rw-r--r-- | sw/source/core/access/acctextframe.cxx | 2 |
4 files changed, 4 insertions, 4 deletions
diff --git a/sw/source/core/access/accframebase.cxx b/sw/source/core/access/accframebase.cxx index a0d3aeacf73a..6338ee18a5c1 100644 --- a/sw/source/core/access/accframebase.cxx +++ b/sw/source/core/access/accframebase.cxx @@ -215,7 +215,7 @@ void SwAccessibleFrameBase::Notify(const SfxHint& rHint) } else if(auto pLegacyModifyHint = dynamic_cast<const sw::LegacyModifyHint*>(&rHint)) { - sal_uInt16 nWhich = pLegacyModifyHint->m_pOld ? pLegacyModifyHint->m_pOld->Which() : pLegacyModifyHint->m_pNew ? pLegacyModifyHint->m_pNew->Which() : 0; + const sal_uInt16 nWhich = pLegacyModifyHint->GetWhich(); const SwFlyFrame* pFlyFrame = static_cast<const SwFlyFrame*>(GetFrame()); if(nWhich == RES_NAME_CHANGED && pFlyFrame) { diff --git a/sw/source/core/access/accnotextframe.cxx b/sw/source/core/access/accnotextframe.cxx index acc4f0ce31a5..3dfed9ea3303 100644 --- a/sw/source/core/access/accnotextframe.cxx +++ b/sw/source/core/access/accnotextframe.cxx @@ -89,7 +89,7 @@ void SwAccessibleNoTextFrame::Notify(const SfxHint& rHint) EndListeningAll(); else if(auto pLegacyModifyHint = dynamic_cast<const sw::LegacyModifyHint*>(&rHint)) { - const sal_uInt16 nWhich = pLegacyModifyHint->m_pOld ? pLegacyModifyHint->m_pOld->Which() : pLegacyModifyHint->m_pNew ? pLegacyModifyHint->m_pNew->Which() : 0; + const sal_uInt16 nWhich = pLegacyModifyHint->GetWhich(); if (nWhich != RES_TITLE_CHANGED && nWhich != RES_DESCRIPTION_CHANGED) return; const SwNoTextNode* pNd = GetNoTextNode(); diff --git a/sw/source/core/access/acctable.cxx b/sw/source/core/access/acctable.cxx index 9e164c7c5696..457e5451dc3b 100644 --- a/sw/source/core/access/acctable.cxx +++ b/sw/source/core/access/acctable.cxx @@ -641,7 +641,7 @@ void SwAccessibleTable::Notify(const SfxHint& rHint) } else if(auto pLegacyHint = dynamic_cast<const sw::LegacyModifyHint*>(&rHint)) { - sal_uInt16 nWhich = pLegacyHint->m_pOld ? pLegacyHint->m_pOld->Which() : pLegacyHint->m_pNew ? pLegacyHint->m_pNew->Which() : 0; + const sal_uInt16 nWhich = pLegacyHint->GetWhich(); const SwTabFrame* pTabFrame = static_cast<const SwTabFrame*>(GetFrame()); if(nWhich == RES_NAME_CHANGED && pTabFrame) { diff --git a/sw/source/core/access/acctextframe.cxx b/sw/source/core/access/acctextframe.cxx index 928a68677283..95937bbd1e99 100644 --- a/sw/source/core/access/acctextframe.cxx +++ b/sw/source/core/access/acctextframe.cxx @@ -69,7 +69,7 @@ void SwAccessibleTextFrame::Notify(const SfxHint& rHint) EndListeningAll(); else if(auto pLegacyModifyHint = dynamic_cast<const sw::LegacyModifyHint*>(&rHint)) { - const sal_uInt16 nWhich = pLegacyModifyHint->m_pOld ? pLegacyModifyHint->m_pOld->Which() : pLegacyModifyHint->m_pNew ? pLegacyModifyHint->m_pNew->Which() : 0; + const sal_uInt16 nWhich = pLegacyModifyHint->GetWhich(); const SwFlyFrame* pFlyFrame = static_cast<const SwFlyFrame*>(GetFrame()); switch(nWhich) { |