diff options
Diffstat (limited to 'sw/source/uibase')
-rw-r--r-- | sw/source/uibase/app/docsh.cxx | 6 | ||||
-rw-r--r-- | sw/source/uibase/app/docst.cxx | 2 | ||||
-rw-r--r-- | sw/source/uibase/config/modcfg.cxx | 2 | ||||
-rw-r--r-- | sw/source/uibase/docvw/edtwin.cxx | 2 | ||||
-rw-r--r-- | sw/source/uibase/shells/basesh.cxx | 2 | ||||
-rw-r--r-- | sw/source/uibase/shells/frmsh.cxx | 2 | ||||
-rw-r--r-- | sw/source/uibase/uiview/viewtab.cxx | 4 | ||||
-rw-r--r-- | sw/source/uibase/uno/unotxdoc.cxx | 2 | ||||
-rw-r--r-- | sw/source/uibase/utlui/uitool.cxx | 4 |
9 files changed, 13 insertions, 13 deletions
diff --git a/sw/source/uibase/app/docsh.cxx b/sw/source/uibase/app/docsh.cxx index 029bccef8456..ff2fd5c76088 100644 --- a/sw/source/uibase/app/docsh.cxx +++ b/sw/source/uibase/app/docsh.cxx @@ -338,7 +338,7 @@ bool SwDocShell::Save() if (m_pDoc->ContainsMSVBasic()) { if( SvtFilterOptions::Get().IsLoadWordBasicStorage() ) - nVBWarning = GetSaveWarningOfMSVBAStorage( (SfxObjectShell&) (*this) ); + nVBWarning = GetSaveWarningOfMSVBAStorage( static_cast<SfxObjectShell&>(*this) ); m_pDoc->SetContainsMSVBasic( false ); } @@ -463,7 +463,7 @@ bool SwDocShell::SaveAs( SfxMedium& rMedium ) if (m_pDoc->ContainsMSVBasic()) { if( SvtFilterOptions::Get().IsLoadWordBasicStorage() ) - nVBWarning = GetSaveWarningOfMSVBAStorage( (SfxObjectShell&) *this ); + nVBWarning = GetSaveWarningOfMSVBAStorage( static_cast<SfxObjectShell&>(*this) ); m_pDoc->SetContainsMSVBasic( false ); } @@ -565,7 +565,7 @@ bool SwDocShell::ConvertTo( SfxMedium& rMedium ) OSL_ENSURE( !xStg->GetError(), "No storage available for storing VBA macros!" ); if ( !xStg->GetError() ) { - nVBWarning = SaveOrDelMSVBAStorage( (SfxObjectShell&) *this, *xStg, bSave, "Macros" ); + nVBWarning = SaveOrDelMSVBAStorage( static_cast<SfxObjectShell&>(*this), *xStg, bSave, "Macros" ); xStg->Commit(); m_pDoc->SetContainsMSVBasic( true ); } diff --git a/sw/source/uibase/app/docst.cxx b/sw/source/uibase/app/docst.cxx index 147212a01181..f78d7126faeb 100644 --- a/sw/source/uibase/app/docst.cxx +++ b/sw/source/uibase/app/docst.cxx @@ -1256,7 +1256,7 @@ SfxStyleFamily SwDocShell::MakeByExample( const OUString &rName, SfxStyleFamily { pCurrWrtShell->StartAllAction(); size_t nPgDsc = pCurrWrtShell->GetCurPageDesc(); - SwPageDesc& rSrc = (SwPageDesc&)pCurrWrtShell->GetPageDesc( nPgDsc ); + SwPageDesc& rSrc = const_cast<SwPageDesc&>(pCurrWrtShell->GetPageDesc( nPgDsc )); SwPageDesc& rDest = *const_cast<SwPageDesc*>(pStyle->GetPageDesc()); sal_uInt16 nPoolId = rDest.GetPoolFormatId(); diff --git a/sw/source/uibase/config/modcfg.cxx b/sw/source/uibase/config/modcfg.cxx index 793d5cc8b019..af7f1d01d024 100644 --- a/sw/source/uibase/config/modcfg.cxx +++ b/sw/source/uibase/config/modcfg.cxx @@ -625,7 +625,7 @@ static void lcl_WriteOpt(const InsCaptionOpt& rOpt, Any* pValues, sal_Int32 nPro case 5: pValues[nProp] <<= rOpt.GetSeparator();break;//Delimiter", case 6: pValues[nProp] <<= (sal_Int32)rOpt.GetLevel(); break;//Level", case 7: pValues[nProp] <<= (sal_Int32)rOpt.GetPos(); break;//Position", - case 8: pValues[nProp] <<= (OUString&)rOpt.GetCharacterStyle(); break; //CharacterStyle + case 8: pValues[nProp] <<= rOpt.GetCharacterStyle(); break; //CharacterStyle case 9: pValues[nProp] <<= rOpt.CopyAttributes(); break; //ApplyAttributes } } diff --git a/sw/source/uibase/docvw/edtwin.cxx b/sw/source/uibase/docvw/edtwin.cxx index f69e8c64184d..d1779e0b11b0 100644 --- a/sw/source/uibase/docvw/edtwin.cxx +++ b/sw/source/uibase/docvw/edtwin.cxx @@ -1524,7 +1524,7 @@ void SwEditWin::KeyInput(const KeyEvent &rKEvt) ((nLclSelectionType & (SelectionType::DrawObject|SelectionType::DbForm)) && rSh.GetDrawView()->GetMarkedObjectList().GetMarkCount() == 1)))) { - SdrHdlList& rHdlList = (SdrHdlList&)rSh.GetDrawView()->GetHdlList(); + SdrHdlList& rHdlList = const_cast<SdrHdlList&>(rSh.GetDrawView()->GetHdlList()); SdrHdl* pAnchor = rHdlList.GetHdl(SdrHdlKind::Anchor); if ( ! pAnchor ) pAnchor = rHdlList.GetHdl(SdrHdlKind::Anchor_TR); diff --git a/sw/source/uibase/shells/basesh.cxx b/sw/source/uibase/shells/basesh.cxx index 48c4a0d0d7ca..53c80f3560f5 100644 --- a/sw/source/uibase/shells/basesh.cxx +++ b/sw/source/uibase/shells/basesh.cxx @@ -2534,7 +2534,7 @@ void SwBaseShell::ExecDlg(SfxRequest &rReq) OSL_ENSURE(pDlg, "Dialog creation failed!"); if ( pDlg->Execute() == RET_OK ) { - rSh.SetFlyFrameAttr((SfxItemSet &) *pDlg->GetOutputItemSet() ); + rSh.SetFlyFrameAttr(const_cast<SfxItemSet &>(*pDlg->GetOutputItemSet()) ); pOutSet = pDlg->GetOutputItemSet(); } } diff --git a/sw/source/uibase/shells/frmsh.cxx b/sw/source/uibase/shells/frmsh.cxx index db817ffaa3e2..11cb198d88e2 100644 --- a/sw/source/uibase/shells/frmsh.cxx +++ b/sw/source/uibase/shells/frmsh.cxx @@ -233,7 +233,7 @@ void SwFrameShell::Execute(SfxRequest &rReq) break; case FN_FRAME_UNCHAIN: - rSh.Unchain( (SwFrameFormat&)*rSh.GetFlyFrameFormat() ); + rSh.Unchain( *rSh.GetFlyFrameFormat() ); GetView().GetViewFrame()->GetBindings().Invalidate(FN_FRAME_CHAIN); break; case FN_FORMAT_FOOTNOTE_DLG: diff --git a/sw/source/uibase/uiview/viewtab.cxx b/sw/source/uibase/uiview/viewtab.cxx index 7eff56c3f7e0..698b994b5f46 100644 --- a/sw/source/uibase/uiview/viewtab.cxx +++ b/sw/source/uibase/uiview/viewtab.cxx @@ -1599,14 +1599,14 @@ void SwView::StateTabWin(SfxItemSet& rSet) const SwFormatHeader& rHeaderFormat = rMaster.GetHeader(); SwFrameFormat *pHeaderFormat = const_cast<SwFrameFormat*>(rHeaderFormat.GetHeaderFormat()); if( pHeaderFormat )// #i80890# if rDesc is not the one belonging to the current page is might crash - pBox = & (const SvxBoxItem&)pHeaderFormat->GetBox(); + pBox = & pHeaderFormat->GetBox(); } else if(nFrameType & FrameTypeFlags::FOOTER ) { const SwFormatFooter& rFooterFormat = rMaster.GetFooter(); SwFrameFormat *pFooterFormat = const_cast<SwFrameFormat*>(rFooterFormat.GetFooterFormat()); if( pFooterFormat )// #i80890# if rDesc is not the one belonging to the current page is might crash - pBox = & (const SvxBoxItem&)pFooterFormat->GetBox(); + pBox = & pFooterFormat->GetBox(); } if(pBox) { diff --git a/sw/source/uibase/uno/unotxdoc.cxx b/sw/source/uibase/uno/unotxdoc.cxx index 45606c4193f9..755d2497cf1d 100644 --- a/sw/source/uibase/uno/unotxdoc.cxx +++ b/sw/source/uibase/uno/unotxdoc.cxx @@ -3700,7 +3700,7 @@ uno::Sequence< lang::Locale > SAL_CALL SwXTextDocument::getDocumentLanguages( SdrOutliner* pOutliner = pSdrView->GetTextEditOutliner(); if(pOutliner) { - EditEngine& rEditEng = (EditEngine&)pOutliner->GetEditEngine(); + EditEngine& rEditEng = const_cast<EditEngine&>(pOutliner->GetEditEngine()); sal_Int32 nParCount = pOutliner->GetParagraphCount(); for (sal_Int32 nPar=0; nPar<nParCount; nPar++) { diff --git a/sw/source/uibase/utlui/uitool.cxx b/sw/source/uibase/utlui/uitool.cxx index 887b75e76271..45afe60c1520 100644 --- a/sw/source/uibase/utlui/uitool.cxx +++ b/sw/source/uibase/utlui/uitool.cxx @@ -559,7 +559,7 @@ void PageDescToItemSet( const SwPageDesc& rPageDesc, SfxItemSet& rSet) } // Integrate footnotes - SwPageFootnoteInfo& rInfo = (SwPageFootnoteInfo&)rPageDesc.GetFootnoteInfo(); + SwPageFootnoteInfo& rInfo = const_cast<SwPageFootnoteInfo&>(rPageDesc.GetFootnoteInfo()); SwPageFootnoteInfoItem aFootnoteItem(rInfo); rSet.Put(aFootnoteItem); @@ -627,7 +627,7 @@ void SfxToSwPageDescAttr( const SwWrtShell& rShell, SfxItemSet& rSet ) { // Delete only, if PageDesc will be enabled! rSet.ClearItem( RES_BREAK ); - SwPageDesc* pDesc = ((SwWrtShell&)rShell).FindPageDescByName( + SwPageDesc* pDesc = const_cast<SwWrtShell&>(rShell).FindPageDescByName( rDescName, true ); if( pDesc ) aPgDesc.RegisterToPageDesc( *pDesc ); |