From 3b34655cc5ba586a616533e2efe3426d7c4e5aef Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Fri, 3 Oct 2014 09:18:24 +0200 Subject: loplugin: cstylecast Change-Id: Id2b5b2510fb13f77592d7a0455f34ccd8a20c2d7 --- svx/source/dialog/dlgctl3d.cxx | 2 +- svx/source/dialog/dlgutil.cxx | 6 +++--- svx/source/dialog/langbox.cxx | 8 ++++---- 3 files changed, 8 insertions(+), 8 deletions(-) (limited to 'svx/source/dialog') diff --git a/svx/source/dialog/dlgctl3d.cxx b/svx/source/dialog/dlgctl3d.cxx index 32b37bc67ef5..7371223a4fb2 100644 --- a/svx/source/dialog/dlgctl3d.cxx +++ b/svx/source/dialog/dlgctl3d.cxx @@ -31,7 +31,7 @@ #include #include #include -#include +#include #include #include #include "helpid.hrc" diff --git a/svx/source/dialog/dlgutil.cxx b/svx/source/dialog/dlgutil.cxx index 0bf0012f7bdf..a159d80a22c5 100644 --- a/svx/source/dialog/dlgutil.cxx +++ b/svx/source/dialog/dlgutil.cxx @@ -33,7 +33,7 @@ FieldUnit GetModuleFieldUnit( const SfxItemSet& rSet ) FieldUnit eUnit = FUNIT_INCH; const SfxPoolItem* pItem = NULL; if ( SfxItemState::SET == rSet.GetItemState( SID_ATTR_METRIC, false, &pItem ) ) - eUnit = (FieldUnit)( (const SfxUInt16Item*)pItem )->GetValue(); + eUnit = (FieldUnit) static_cast(pItem)->GetValue(); else { return SfxModule::GetCurrentFieldUnit(); @@ -47,7 +47,7 @@ bool GetApplyCharUnit( const SfxItemSet& rSet ) bool bUseCharUnit = false; const SfxPoolItem* pItem = NULL; if ( SfxItemState::SET == rSet.GetItemState( SID_ATTR_APPLYCHARUNIT, false, &pItem ) ) - bUseCharUnit = ((const SfxBoolItem*)pItem )->GetValue(); + bUseCharUnit = static_cast(pItem)->GetValue(); else { // FIXME - this might be wrong, cf. the DEV300 changes in GetModuleFieldUnit() @@ -62,7 +62,7 @@ bool GetApplyCharUnit( const SfxItemSet& rSet ) { pItem = pModule->GetItem( SID_ATTR_APPLYCHARUNIT ); if ( pItem ) - bUseCharUnit = ((SfxBoolItem*)pItem )->GetValue(); + bUseCharUnit = static_cast(pItem)->GetValue(); } else { diff --git a/svx/source/dialog/langbox.cxx b/svx/source/dialog/langbox.cxx index eec98dee33a4..e8a0128c86db 100644 --- a/svx/source/dialog/langbox.cxx +++ b/svx/source/dialog/langbox.cxx @@ -358,7 +358,7 @@ sal_Int32 SvxLanguageBoxBase::ImplInsertLanguage( const LanguageType nLangType, else nAt = ImplInsertEntry( aStrEntry, nPos ); - ImplSetEntryData( nAt, (void*)(sal_uIntPtr)nLangType ); + ImplSetEntryData( nAt, reinterpret_cast(nLangType) ); return nAt; } @@ -394,7 +394,7 @@ sal_Int32 SvxLanguageBoxBase::InsertLanguage( const LanguageType nLangType, aStrEntry = m_aAllString; sal_Int32 nAt = ImplInsertImgEntry( aStrEntry, nPos, bCheckEntry ); - ImplSetEntryData( nAt, (void*)(sal_uIntPtr)nLang ); + ImplSetEntryData( nAt, reinterpret_cast(nLang) ); return nAt; } @@ -414,7 +414,7 @@ LanguageType SvxLanguageBoxBase::GetSelectLanguage() const sal_Int32 nPos = ImplGetSelectEntryPos(); if ( nPos != LISTBOX_ENTRY_NOTFOUND ) - return LanguageType( (sal_uIntPtr)ImplGetEntryData(nPos) ); + return LanguageType( reinterpret_cast(ImplGetEntryData(nPos)) ); else return LanguageType( LANGUAGE_DONTKNOW ); } @@ -452,7 +452,7 @@ bool SvxLanguageBoxBase::IsLanguageSelected( const LanguageType eLangType ) cons sal_Int32 SvxLanguageBoxBase::ImplTypeToPos( LanguageType eType ) const { - return ImplGetEntryPos( (void*)(sal_uIntPtr)eType); + return ImplGetEntryPos( reinterpret_cast(eType) ); } -- cgit