diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2019-08-27 11:06:41 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2019-08-27 18:42:13 +0200 |
commit | 9e0b3423f21c23a8ef2fe749ea7dd7c1194c2f9a (patch) | |
tree | 26f2674f88359c5e6c3e1d0f888c7b31836c36ee /sd | |
parent | bbd500e14fce92b27cfc09e7cffd346e36eb5fb0 (diff) |
loplugin:referencecasting find more redundant static_cast
Change-Id: I3a51812bbd3fcdc6b11e47cb12962f0d4fa7a2ae
Reviewed-on: https://gerrit.libreoffice.org/78191
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sd')
-rw-r--r-- | sd/source/core/drawdoc3.cxx | 2 | ||||
-rw-r--r-- | sd/source/ui/app/sdmod2.cxx | 2 | ||||
-rw-r--r-- | sd/source/ui/unoidl/unocpres.cxx | 2 | ||||
-rw-r--r-- | sd/source/ui/view/FormShellManager.cxx | 2 | ||||
-rw-r--r-- | sd/source/ui/view/viewshe2.cxx | 3 |
5 files changed, 5 insertions, 6 deletions
diff --git a/sd/source/core/drawdoc3.cxx b/sd/source/core/drawdoc3.cxx index b6721acbc0e6..9aac00728c05 100644 --- a/sd/source/core/drawdoc3.cxx +++ b/sd/source/core/drawdoc3.cxx @@ -1573,7 +1573,7 @@ void SdDrawDocument::SetMasterPage(sal_uInt16 nSdPageNum, aReplList.push_back(aReplData); } - pHisSheet = static_cast<SfxStyleSheet*>( pSourceStyleSheetPool->Next() ); + pHisSheet = pSourceStyleSheetPool->Next(); } // If new styles were created: re-create parent chaining of the item diff --git a/sd/source/ui/app/sdmod2.cxx b/sd/source/ui/app/sdmod2.cxx index 4fd801e92b5f..5379f25aabde 100644 --- a/sd/source/ui/app/sdmod2.cxx +++ b/sd/source/ui/app/sdmod2.cxx @@ -500,7 +500,7 @@ std::unique_ptr<SfxItemSet> SdModule::CreateItemSet( sal_uInt16 nSlot ) sal_Int32 nY; if( pDocSh ) { - SdrPage* pPage = static_cast<SdrPage*>(pDoc->GetSdPage(0, PageKind::Standard)); + SdrPage* pPage = pDoc->GetSdPage(0, PageKind::Standard); Size aSize(pPage->GetSize()); nW = aSize.Width(); nH = aSize.Height(); diff --git a/sd/source/ui/unoidl/unocpres.cxx b/sd/source/ui/unoidl/unocpres.cxx index 43cceb0dae39..2571b1388bbf 100644 --- a/sd/source/ui/unoidl/unocpres.cxx +++ b/sd/source/ui/unoidl/unocpres.cxx @@ -186,7 +186,7 @@ uno::Any SAL_CALL SdXCustomPresentation::getByIndex( sal_Int32 Index ) throw lang::IndexOutOfBoundsException(); uno::Any aAny; - SdrPage * pPage = static_cast<SdrPage*>(const_cast<SdPage *>(mpSdCustomShow->PagesVector()[Index])); + SdrPage * pPage = const_cast<SdPage *>(mpSdCustomShow->PagesVector()[Index]); if( pPage ) { diff --git a/sd/source/ui/view/FormShellManager.cxx b/sd/source/ui/view/FormShellManager.cxx index 8116b2a3359d..fa86b58ec904 100644 --- a/sd/source/ui/view/FormShellManager.cxx +++ b/sd/source/ui/view/FormShellManager.cxx @@ -109,7 +109,7 @@ void FormShellManager::SetFormShell (FmFormShell* pFormShell) if (pMainViewShell != nullptr) { // Prevent setting the view twice at the FmFormShell. - FmFormView* pFormView = static_cast<FmFormView*>(pMainViewShell->GetView()); + FmFormView* pFormView = pMainViewShell->GetView(); if (mpFormShell->GetFormView() != pFormView) mpFormShell->SetView(pFormView); } diff --git a/sd/source/ui/view/viewshe2.cxx b/sd/source/ui/view/viewshe2.cxx index f5e511d21a0e..707b8ac4c511 100644 --- a/sd/source/ui/view/viewshe2.cxx +++ b/sd/source/ui/view/viewshe2.cxx @@ -752,8 +752,7 @@ bool ViewShell::ActivateObject(SdrOle2Obj* pObj, long nVerb) } SfxInPlaceClient* pSdClient = - static_cast<Client*>(pViewShell->FindIPClient( - pObj->GetObjRef(), GetActiveWindow())); + pViewShell->FindIPClient(pObj->GetObjRef(), GetActiveWindow()); if ( !pSdClient ) { |