[Libreoffice-commits] core.git: accessibility/source basctl/source basic/source canvas/source chart2/source comphelper/source compilerplugins/clang connectivity/source cppuhelper/source cui/source dbaccess/source drawinglayer/source editeng/source extensions/source filter/source forms/source fpicker/source framework/source io/source linguistic/source lotuswordpro/source oox/source pyuno/source reportdesign/source rsc/source scaddins/source sc/source sd/source sfx2/source stoc/source svtools/source svx/source sw/source toolkit/source ucb/source vcl/source writerfilter/source xmloff/source
Noel Grandin
noel.grandin at collabora.co.uk
Thu Mar 23 09:48:38 UTC 2017
accessibility/source/helper/characterattributeshelper.cxx | 4 -
accessibility/source/standard/vclxaccessiblelist.cxx | 10 ++--
accessibility/source/standard/vclxaccessiblescrollbar.cxx | 4 -
basctl/source/basicide/moduldl2.cxx | 2
basctl/source/dlged/dlgedobj.cxx | 2
basic/source/classes/sb.cxx | 2
basic/source/classes/sbunoobj.cxx | 14 +++---
basic/source/runtime/iosys.cxx | 2
basic/source/runtime/methods.cxx | 6 +-
basic/source/sbx/sbxbool.cxx | 4 -
basic/source/sbx/sbxint.cxx | 2
canvas/source/vcl/canvashelper.cxx | 3 -
chart2/source/view/main/ShapeFactory.cxx | 2
comphelper/source/container/container.cxx | 2
compilerplugins/clang/redundantcast.cxx | 10 ++++
connectivity/source/commontools/dbtools.cxx | 2
connectivity/source/drivers/calc/CTable.cxx | 4 -
connectivity/source/drivers/dbase/DTable.cxx | 6 +-
connectivity/source/drivers/file/FNoException.cxx | 2
connectivity/source/drivers/file/FResultSetMetaData.cxx | 2
connectivity/source/drivers/jdbc/DatabaseMetaData.cxx | 8 +--
connectivity/source/drivers/jdbc/JStatement.cxx | 10 ++--
connectivity/source/drivers/jdbc/PreparedStatement.cxx | 8 +--
connectivity/source/drivers/jdbc/ResultSet.cxx | 2
connectivity/source/drivers/mork/MResultSet.cxx | 4 -
connectivity/source/drivers/mork/MResultSetMetaData.cxx | 2
connectivity/source/drivers/postgresql/pq_preparedstatement.cxx | 4 -
connectivity/source/drivers/postgresql/pq_tools.cxx | 4 -
cppuhelper/source/propshlp.cxx | 8 +--
cui/source/options/optinet2.cxx | 3 -
cui/source/tabpages/swpossizetabpage.cxx | 6 --
cui/source/tabpages/tabstpge.cxx | 6 +-
dbaccess/source/filter/xml/xmlDataSourceSetting.cxx | 2
dbaccess/source/ui/browser/formadapter.cxx | 2
dbaccess/source/ui/querydesign/TableFieldDescription.cxx | 2
drawinglayer/source/primitive2d/sceneprimitive2d.cxx | 4 -
editeng/source/accessibility/AccessibleEditableTextPara.cxx | 2
editeng/source/editeng/editdoc.cxx | 2
editeng/source/editeng/editview.cxx | 2
editeng/source/editeng/impedit2.cxx | 4 -
editeng/source/editeng/impedit3.cxx | 10 ++--
editeng/source/items/bulitem.cxx | 2
editeng/source/items/textitem.cxx | 4 -
editeng/source/misc/unolingu.cxx | 2
extensions/source/propctrlr/formcomponenthandler.cxx | 2
extensions/source/propctrlr/formmetadata.cxx | 2
filter/source/graphicfilter/eps/eps.cxx | 10 ++--
filter/source/graphicfilter/ipict/ipict.cxx | 2
filter/source/graphicfilter/ipsd/ipsd.cxx | 12 ++---
filter/source/graphicfilter/itiff/itiff.cxx | 2
filter/source/msfilter/eschesdo.cxx | 3 -
filter/source/msfilter/svdfppt.cxx | 10 ++--
filter/source/pdf/impdialog.cxx | 2
filter/source/svg/svgwriter.cxx | 2
filter/source/xsltdialog/xmlfiltertabdialog.cxx | 2
forms/source/component/Columns.cxx | 2
forms/source/component/DatabaseForm.cxx | 2
forms/source/component/EditBase.cxx | 2
forms/source/component/FormattedField.cxx | 2
forms/source/component/Grid.cxx | 6 +-
forms/source/runtime/formoperations.cxx | 6 +-
fpicker/source/office/OfficeControlAccess.cxx | 2
framework/source/accelerators/keymapping.cxx | 2
framework/source/fwe/helper/titlehelper.cxx | 8 +--
framework/source/fwi/classes/converter.cxx | 12 ++---
io/source/acceptor/acc_socket.cxx | 4 -
io/source/connector/ctr_socket.cxx | 4 -
linguistic/source/dicimp.cxx | 2
lotuswordpro/source/filter/xfilter/xfbase64.cxx | 6 +-
oox/source/drawingml/customshapegeometry.cxx | 2
oox/source/ppt/commontimenodecontext.cxx | 4 -
oox/source/ppt/pptshape.cxx | 2
oox/source/ppt/timenodelistcontext.cxx | 2
pyuno/source/module/pyuno_adapter.cxx | 2
reportdesign/source/filter/xml/xmlControlProperty.cxx | 2
rsc/source/res/rscconst.cxx | 4 -
rsc/source/res/rsccont.cxx | 4 -
rsc/source/res/rscflag.cxx | 2
rsc/source/res/rscrange.cxx | 4 -
rsc/source/tools/rsctree.cxx | 4 -
sc/source/core/data/attarray.cxx | 16 +++----
sc/source/core/data/column3.cxx | 2
sc/source/core/data/poolhelp.cxx | 2
sc/source/core/data/table2.cxx | 4 -
sc/source/core/tool/appoptio.cxx | 4 -
sc/source/core/tool/interpr1.cxx | 2
sc/source/filter/html/htmlexp.cxx | 4 -
sc/source/filter/starcalc/scflt.cxx | 2
sc/source/filter/xcl97/xcl97rec.cxx | 2
sc/source/ui/Accessibility/AccessibleCellBase.cxx | 2
sc/source/ui/dbgui/scuiimoptdlg.cxx | 4 -
sc/source/ui/dbgui/validate.cxx | 2
sc/source/ui/docshell/docsh8.cxx | 2
sc/source/ui/drawfunc/drtxtob.cxx | 3 -
sc/source/ui/optdlg/tpview.cxx | 3 -
sc/source/ui/unoobj/appluno.cxx | 2
sc/source/ui/view/select.cxx | 2
sc/source/ui/view/tabview3.cxx | 2
scaddins/source/analysis/analysishelper.cxx | 2
scaddins/source/datefunc/datefunc.cxx | 2
sd/source/filter/eppt/pptx-epptooxml.cxx | 4 -
sd/source/filter/ppt/pptinanimations.cxx | 4 -
sd/source/ui/app/optsitem.cxx | 4 -
sd/source/ui/app/sdmod2.cxx | 2
sd/source/ui/dlg/present.cxx | 2
sd/source/ui/dlg/tpoption.cxx | 3 -
sd/source/ui/docshell/docshel2.cxx | 2
sd/source/ui/func/futext.cxx | 4 -
sd/source/ui/unoidl/unomodel.cxx | 2
sd/source/ui/unoidl/unopage.cxx | 10 ++--
sd/source/ui/view/drtxtob.cxx | 2
sfx2/source/dialog/versdlg.cxx | 4 -
sfx2/source/doc/objcont.cxx | 2
stoc/source/inspect/introspection.cxx | 2
svtools/source/contnr/imivctl2.cxx | 2
svtools/source/dialogs/colrdlg.cxx | 2
svtools/source/dialogs/roadmapwizard.cxx | 4 -
svx/source/customshapes/EnhancedCustomShapeFontWork.cxx | 2
svx/source/fmcomp/gridctrl.cxx | 4 -
svx/source/form/fmpgeimp.cxx | 2
svx/source/form/fmshell.cxx | 2
svx/source/form/fmshimp.cxx | 2
svx/source/form/formcontrolfactory.cxx | 6 +-
svx/source/svdraw/svdattr.cxx | 8 +--
svx/source/svdraw/svdfmtf.cxx | 2
svx/source/svdraw/svdlayer.cxx | 2
svx/source/svdraw/svdopath.cxx | 2
svx/source/tbxctrls/extrusioncontrols.cxx | 4 -
svx/source/tbxctrls/fontworkgallery.cxx | 6 +-
svx/source/unodraw/UnoGraphicExporter.cxx | 2
svx/source/unodraw/unoshap4.cxx | 2
svx/source/unodraw/unoshape.cxx | 2
svx/source/xoutdev/xattr.cxx | 4 -
sw/source/core/doc/docbasic.cxx | 2
sw/source/core/doc/htmltbl.cxx | 8 +--
sw/source/core/edit/editsh.cxx | 4 -
sw/source/core/inc/swfont.hxx | 2
sw/source/core/text/inftxt.cxx | 2
sw/source/core/tox/tox.cxx | 2
sw/source/core/unocore/unoidx.cxx | 2
sw/source/core/unocore/unosett.cxx | 2
sw/source/filter/html/htmlform.cxx | 18 ++++----
sw/source/filter/html/htmlnumreader.cxx | 2
sw/source/filter/ww8/rtfattributeoutput.cxx | 14 +++---
sw/source/filter/ww8/wrtw8sty.cxx | 4 -
sw/source/filter/xml/xmlimpit.cxx | 4 -
sw/source/uibase/fldui/fldmgr.cxx | 4 -
sw/source/uibase/inc/toxmgr.hxx | 2
sw/source/uibase/uiview/view2.cxx | 2
toolkit/source/awt/vclxspinbutton.cxx | 8 +--
toolkit/source/awt/vclxwindow.cxx | 2
toolkit/source/awt/vclxwindows.cxx | 16 +++----
toolkit/source/controls/unocontrols.cxx | 8 +--
ucb/source/ucp/ftp/ftpurl.cxx | 2
vcl/source/control/imp_listbox.cxx | 4 -
vcl/source/filter/sgvmain.cxx | 2
vcl/source/gdi/bitmap.cxx | 4 -
vcl/source/gdi/dibtools.cxx | 2
vcl/source/gdi/pdfwriter_impl.cxx | 4 -
vcl/source/gdi/pdfwriter_impl2.cxx | 2
vcl/source/gdi/pngread.cxx | 2
vcl/source/outdev/outdev.cxx | 2
vcl/source/outdev/transparent.cxx | 2
vcl/source/window/menubarwindow.cxx | 2
vcl/source/window/menufloatingwindow.cxx | 2
writerfilter/source/dmapper/DomainMapperTableHandler.cxx | 6 +-
writerfilter/source/rtftok/rtfdocumentimpl.cxx | 4 -
xmloff/source/draw/animationimport.cxx | 4 -
xmloff/source/forms/propertyimport.cxx | 2
xmloff/source/style/cdouthdl.cxx | 2
xmloff/source/style/xmlnume.cxx | 2
xmloff/source/style/xmlnumi.cxx | 22 +++++-----
xmloff/source/style/xmlstyle.cxx | 4 -
xmloff/source/text/txtfldi.cxx | 4 -
xmloff/source/text/txtparae.cxx | 4 -
175 files changed, 347 insertions(+), 345 deletions(-)
New commits:
commit ed76d1d3504c92bff6bb3e6417e4440572fcd959
Author: Noel Grandin <noel.grandin at collabora.co.uk>
Date: Thu Mar 23 09:47:49 2017 +0200
loplugins:redundantcast teach it about c-style typedef casts
Change-Id: I1ac11a2481c0f4d8be1e1fd7c7637ac0ece3d65c
Reviewed-on: https://gerrit.libreoffice.org/35558
Tested-by: Jenkins <ci at libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin at collabora.co.uk>
diff --git a/accessibility/source/helper/characterattributeshelper.cxx b/accessibility/source/helper/characterattributeshelper.cxx
index c99b1097678f..7a88351c91a2 100644
--- a/accessibility/source/helper/characterattributeshelper.cxx
+++ b/accessibility/source/helper/characterattributeshelper.cxx
@@ -27,8 +27,8 @@ using namespace ::com::sun::star::beans;
CharacterAttributesHelper::CharacterAttributesHelper( const vcl::Font& rFont, sal_Int32 nBackColor, sal_Int32 nColor )
{
- m_aAttributeMap.insert( AttributeMap::value_type( OUString( "CharBackColor" ), Any( (sal_Int32) nBackColor ) ) );
- m_aAttributeMap.insert( AttributeMap::value_type( OUString( "CharColor" ), Any( (sal_Int32) nColor ) ) );
+ m_aAttributeMap.insert( AttributeMap::value_type( OUString( "CharBackColor" ), Any( nBackColor ) ) );
+ m_aAttributeMap.insert( AttributeMap::value_type( OUString( "CharColor" ), Any( nColor ) ) );
m_aAttributeMap.insert( AttributeMap::value_type( OUString( "CharFontCharSet" ), Any( (sal_Int16) rFont.GetCharSet() ) ) );
m_aAttributeMap.insert( AttributeMap::value_type( OUString( "CharFontFamily" ), Any( (sal_Int16) rFont.GetFamilyType() ) ) );
m_aAttributeMap.insert( AttributeMap::value_type( OUString( "CharFontName" ), Any( rFont.GetFamilyName() ) ) );
diff --git a/accessibility/source/standard/vclxaccessiblelist.cxx b/accessibility/source/standard/vclxaccessiblelist.cxx
index e82cf5e32817..d314879765cf 100644
--- a/accessibility/source/standard/vclxaccessiblelist.cxx
+++ b/accessibility/source/standard/vclxaccessiblelist.cxx
@@ -45,8 +45,8 @@ namespace
/// @throws css::lang::IndexOutOfBoundsException
void checkSelection_Impl( sal_Int32 _nIndex, const IComboListBoxHelper& _rListBox, bool bSelected )
{
- sal_Int32 nCount = bSelected ? (sal_Int32)_rListBox.GetSelectEntryCount()
- : (sal_Int32)_rListBox.GetEntryCount();
+ sal_Int32 nCount = bSelected ? _rListBox.GetSelectEntryCount()
+ : _rListBox.GetEntryCount();
if ( _nIndex < 0 || _nIndex >= nCount )
throw css::lang::IndexOutOfBoundsException();
}
@@ -254,7 +254,7 @@ void VCLXAccessibleList::UpdateSelection_Impl_Acc(bool bHasDropDownList)
if ( xNewAcc.is() && GetWindow()->HasFocus() )
{
if ( m_nLastSelectedPos != LISTBOX_ENTRY_NOTFOUND )
- aOldValue <<= getAccessibleChild( (sal_Int32)m_nLastSelectedPos );
+ aOldValue <<= getAccessibleChild( m_nLastSelectedPos );
aNewValue <<= xNewAcc;
}
}
@@ -720,7 +720,7 @@ void VCLXAccessibleList::UpdateSelection_Impl(sal_Int32)
if ( xNewAcc.is() && GetWindow()->HasFocus() )
{
if ( m_nLastSelectedPos != LISTBOX_ENTRY_NOTFOUND )
- aOldValue <<= getAccessibleChild( (sal_Int32)m_nLastSelectedPos );
+ aOldValue <<= getAccessibleChild( m_nLastSelectedPos );
aNewValue <<= xNewAcc;
}
if (m_pListBoxHelper->IsInDropDown())
@@ -843,7 +843,7 @@ Reference< XAccessible > SAL_CALL VCLXAccessibleList::getSelectedAccessibleChild
if ( m_pListBoxHelper )
{
checkSelection_Impl(nSelectedChildIndex,*m_pListBoxHelper,true);
- return getAccessibleChild( (sal_Int32)m_pListBoxHelper->GetSelectEntryPos( (sal_uInt16)nSelectedChildIndex ) );
+ return getAccessibleChild( m_pListBoxHelper->GetSelectEntryPos( (sal_uInt16)nSelectedChildIndex ) );
}
return nullptr;
diff --git a/accessibility/source/standard/vclxaccessiblescrollbar.cxx b/accessibility/source/standard/vclxaccessiblescrollbar.cxx
index 68705608f388..cc8745c61c0e 100644
--- a/accessibility/source/standard/vclxaccessiblescrollbar.cxx
+++ b/accessibility/source/standard/vclxaccessiblescrollbar.cxx
@@ -197,7 +197,7 @@ Any VCLXAccessibleScrollBar::getCurrentValue( )
VCLXScrollBar* pVCLXScrollBar = static_cast< VCLXScrollBar* >( GetVCLXWindow() );
if ( pVCLXScrollBar )
- aValue <<= (sal_Int32) pVCLXScrollBar->getValue();
+ aValue <<= pVCLXScrollBar->getValue();
return aValue;
}
@@ -238,7 +238,7 @@ Any VCLXAccessibleScrollBar::getMaximumValue( )
VCLXScrollBar* pVCLXScrollBar = static_cast< VCLXScrollBar* >( GetVCLXWindow() );
if ( pVCLXScrollBar )
- aValue <<= (sal_Int32) pVCLXScrollBar->getMaximum();
+ aValue <<= pVCLXScrollBar->getMaximum();
return aValue;
}
diff --git a/basctl/source/basicide/moduldl2.cxx b/basctl/source/basicide/moduldl2.cxx
index 30f51a98254c..285b34b2bcda 100644
--- a/basctl/source/basicide/moduldl2.cxx
+++ b/basctl/source/basicide/moduldl2.cxx
@@ -682,7 +682,7 @@ IMPL_LINK( LibPage, ButtonHdl, Button *, pButton, void )
if ( bNewProtected != bProtected )
{
- sal_uLong nPos = (sal_uLong)m_pLibBox->GetModel()->GetAbsPos( pCurEntry );
+ sal_uLong nPos = m_pLibBox->GetModel()->GetAbsPos( pCurEntry );
m_pLibBox->GetModel()->Remove( pCurEntry );
ImpInsertLibEntry( aLibName, nPos );
m_pLibBox->SetCurEntry( m_pLibBox->GetEntry( nPos ) );
diff --git a/basctl/source/dlged/dlgedobj.cxx b/basctl/source/dlged/dlgedobj.cxx
index be46d588a6c1..a2e19d0decaa 100644
--- a/basctl/source/dlged/dlgedobj.cxx
+++ b/basctl/source/dlged/dlgedobj.cxx
@@ -1440,7 +1440,7 @@ void DlgEdForm::UpdateTabIndices()
aCtrl >>= xPSet;
if ( xPSet.is() )
{
- xPSet->setPropertyValue( DLGED_PROP_TABINDEX, Any((sal_Int16) nNewTabIndex) );
+ xPSet->setPropertyValue( DLGED_PROP_TABINDEX, Any(nNewTabIndex) );
nNewTabIndex++;
}
}
diff --git a/basic/source/classes/sb.cxx b/basic/source/classes/sb.cxx
index bc89862e9f21..ac87ff6b753e 100644
--- a/basic/source/classes/sb.cxx
+++ b/basic/source/classes/sb.cxx
@@ -560,7 +560,7 @@ SbxObject* cloneTypeObjectImpl( const SbxObject& rTypeObj )
sal_Int32 ub = 0;
for ( sal_Int32 j = 1 ; j <= pSource->GetDims(); ++j )
{
- pSource->GetDim32( (sal_Int32)j, lb, ub );
+ pSource->GetDim32( j, lb, ub );
pDest->AddDim32( lb, ub );
}
}
diff --git a/basic/source/classes/sbunoobj.cxx b/basic/source/classes/sbunoobj.cxx
index 9d4d00d60c0f..971d7b475d0d 100644
--- a/basic/source/classes/sbunoobj.cxx
+++ b/basic/source/classes/sbunoobj.cxx
@@ -1225,7 +1225,7 @@ Any sbxToUnoValue( const SbxValue* pVar, const Type& rType, Property* pUnoProper
else if( rType == cppu::UnoType<oleautomation::Currency>::get())
{
// assumes per previous code that ole Currency is Int64
- aRetVal <<= (sal_Int64)( pVar->GetInt64() );
+ aRetVal <<= pVar->GetInt64();
break;
}
else if( rType == cppu::UnoType<oleautomation::Date>::get())
@@ -1442,12 +1442,12 @@ Any sbxToUnoValue( const SbxValue* pVar, const Type& rType, Property* pUnoProper
aRetVal <<= nByteVal;
break;
}
- case TypeClass_SHORT: aRetVal <<= (sal_Int16)( pVar->GetInteger() ); break;
- case TypeClass_LONG: aRetVal <<= (sal_Int32)( pVar->GetLong() ); break;
- case TypeClass_HYPER: aRetVal <<= (sal_Int64)( pVar->GetInt64() ); break;
- case TypeClass_UNSIGNED_SHORT: aRetVal <<= (sal_uInt16)( pVar->GetUShort() ); break;
- case TypeClass_UNSIGNED_LONG: aRetVal <<= (sal_uInt32)( pVar->GetULong() ); break;
- case TypeClass_UNSIGNED_HYPER: aRetVal <<= (sal_uInt64)( pVar->GetUInt64() ); break;
+ case TypeClass_SHORT: aRetVal <<= pVar->GetInteger(); break;
+ case TypeClass_LONG: aRetVal <<= pVar->GetLong(); break;
+ case TypeClass_HYPER: aRetVal <<= pVar->GetInt64(); break;
+ case TypeClass_UNSIGNED_SHORT: aRetVal <<= pVar->GetUShort(); break;
+ case TypeClass_UNSIGNED_LONG: aRetVal <<= pVar->GetULong(); break;
+ case TypeClass_UNSIGNED_HYPER: aRetVal <<= pVar->GetUInt64(); break;
default: break;
}
diff --git a/basic/source/runtime/iosys.cxx b/basic/source/runtime/iosys.cxx
index 2f816884cfcf..b019f27ad5a4 100644
--- a/basic/source/runtime/iosys.cxx
+++ b/basic/source/runtime/iosys.cxx
@@ -281,7 +281,7 @@ sal_uInt64 OslStream::SeekPos( sal_uInt64 nPos )
}
else
{
- rc = maFile.setPos( osl_Pos_Absolut, (sal_uInt64)nPos );
+ rc = maFile.setPos( osl_Pos_Absolut, nPos );
}
OSL_VERIFY(rc == ::osl::FileBase::E_None);
sal_uInt64 nRealPos(0);
diff --git a/basic/source/runtime/methods.cxx b/basic/source/runtime/methods.cxx
index b5746d01427d..3016a4eae7f5 100644
--- a/basic/source/runtime/methods.cxx
+++ b/basic/source/runtime/methods.cxx
@@ -3494,7 +3494,7 @@ RTLFUNC(Format)
(void)pBasic;
(void)bWrite;
- sal_uInt16 nArgCount = (sal_uInt16)rPar.Count();
+ sal_uInt16 nArgCount = rPar.Count();
if ( nArgCount < 2 || nArgCount > 3 )
{
StarBASIC::Error( ERRCODE_BASIC_BAD_ARGUMENT );
@@ -4518,7 +4518,7 @@ RTLFUNC(MsgBox)
};
- sal_uInt16 nArgCount = (sal_uInt16)rPar.Count();
+ sal_uInt16 nArgCount = rPar.Count();
if( nArgCount < 2 || nArgCount > 6 )
{
StarBASIC::Error( ERRCODE_BASIC_BAD_ARGUMENT );
@@ -4677,7 +4677,7 @@ RTLFUNC(DumpAllObjects)
(void)pBasic;
(void)bWrite;
- sal_uInt16 nArgCount = (sal_uInt16)rPar.Count();
+ sal_uInt16 nArgCount = rPar.Count();
if( nArgCount < 2 || nArgCount > 3 )
{
StarBASIC::Error( ERRCODE_BASIC_BAD_ARGUMENT );
diff --git a/basic/source/sbx/sbxbool.cxx b/basic/source/sbx/sbxbool.cxx
index 8e7e9ccad9fe..2e789bd3d100 100644
--- a/basic/source/sbx/sbxbool.cxx
+++ b/basic/source/sbx/sbxbool.cxx
@@ -168,7 +168,7 @@ void ImpPutBool( SbxValues* p, sal_Int16 n )
p->uInt64 = (sal_uInt64) n; break;
case SbxDECIMAL:
case SbxBYREF | SbxDECIMAL:
- ImpCreateDecimal( p )->setInt( (sal_Int16)n );
+ ImpCreateDecimal( p )->setInt( n );
break;
case SbxBYREF | SbxSTRING:
@@ -195,7 +195,7 @@ void ImpPutBool( SbxValues* p, sal_Int16 n )
*p->pByte = (sal_uInt8) n; break;
case SbxBYREF | SbxINTEGER:
case SbxBYREF | SbxBOOL:
- *p->pInteger = (sal_Int16) n; break;
+ *p->pInteger = n; break;
case SbxBYREF | SbxERROR:
case SbxBYREF | SbxUSHORT:
*p->pUShort = (sal_uInt16) n; break;
diff --git a/basic/source/sbx/sbxint.cxx b/basic/source/sbx/sbxint.cxx
index 41886a68e648..d92a0aadb2c0 100644
--- a/basic/source/sbx/sbxint.cxx
+++ b/basic/source/sbx/sbxint.cxx
@@ -632,7 +632,7 @@ start:
{
SbxBase::SetError( ERRCODE_SBX_OVERFLOW ); n = 0;
}
- *p->puInt64 = (sal_Int64) n; break;
+ *p->puInt64 = n; break;
default:
SbxBase::SetError( ERRCODE_SBX_CONVERSION );
diff --git a/canvas/source/vcl/canvashelper.cxx b/canvas/source/vcl/canvashelper.cxx
index 78036a44ff14..7aebfbc1ac2f 100644
--- a/canvas/source/vcl/canvashelper.cxx
+++ b/canvas/source/vcl/canvashelper.cxx
@@ -1008,8 +1008,7 @@ namespace vclcanvas
rOutDev.SetAntialiasing( AntialiasingFlags::EnableB2dDraw );
const Rectangle aRect( vcl::unotools::rectangleFromIntegerRectangle2D(rect) );
- const sal_uInt16 nBitCount( std::min( (sal_uInt16)24U,
- (sal_uInt16)rOutDev.GetBitCount() ) );
+ const sal_uInt16 nBitCount( std::min( (sal_uInt16)24, rOutDev.GetBitCount() ) );
const BitmapPalette* pPalette = nullptr;
if( nBitCount <= 8 )
diff --git a/chart2/source/view/main/ShapeFactory.cxx b/chart2/source/view/main/ShapeFactory.cxx
index 4a8489425063..9eeed05c303f 100644
--- a/chart2/source/view/main/ShapeFactory.cxx
+++ b/chart2/source/view/main/ShapeFactory.cxx
@@ -669,7 +669,7 @@ uno::Reference<drawing::XShape>
xProp->setPropertyValue( UNO_NAME_3D_HORZ_SEGS
, uno::Any(CHART_3DOBJECT_SEGMENTCOUNT) );
xProp->setPropertyValue( UNO_NAME_3D_VERT_SEGS
- , uno::Any((sal_Int32)nVerticalSegmentCount) );//depends on point count of the used polygon
+ , uno::Any(nVerticalSegmentCount) );//depends on point count of the used polygon
//Reduced lines
xProp->setPropertyValue( UNO_NAME_3D_REDUCED_LINE_GEOMETRY
diff --git a/comphelper/source/container/container.cxx b/comphelper/source/container/container.cxx
index a383a534c102..a2e1833f890c 100644
--- a/comphelper/source/container/container.cxx
+++ b/comphelper/source/container/container.cxx
@@ -94,7 +94,7 @@ css::uno::Reference< css::uno::XInterface> const & IndexAccessIterator::Next()
xSearchLoop = *o3tl::doAccess<css::uno::Reference<css::uno::XInterface>>(aElement);
bCheckingStartingPoint = false;
// and update its position in the list.
- m_arrChildIndizies.push_back((sal_Int32)nOldSearchChildIndex);
+ m_arrChildIndizies.push_back(nOldSearchChildIndex);
break;
}
diff --git a/compilerplugins/clang/redundantcast.cxx b/compilerplugins/clang/redundantcast.cxx
index 4bef116f481b..c18e1cf5be0e 100644
--- a/compilerplugins/clang/redundantcast.cxx
+++ b/compilerplugins/clang/redundantcast.cxx
@@ -304,6 +304,16 @@ bool RedundantCast::VisitCStyleCastExpr(CStyleCastExpr const * expr) {
DiagnosticsEngine::Warning,
"redundant cstyle enum cast from %0 to %1", expr->getExprLoc())
<< t1 << t2 << expr->getSourceRange();
+ return true;
+ }
+ if (loplugin::TypeCheck(t1).Typedef() && loplugin::TypeCheck(t2).Typedef() && t1 == t2
+ && !compiler.getSourceManager().isMacroBodyExpansion(expr->getLocStart()))
+ {
+ report(
+ DiagnosticsEngine::Warning,
+ "redundant cstyle typedef cast from %0 to %1", expr->getExprLoc())
+ << t1 << t2 << expr->getSourceRange();
+ return true;
}
return true;
}
diff --git a/connectivity/source/commontools/dbtools.cxx b/connectivity/source/commontools/dbtools.cxx
index f883b576ee4d..341870bda331 100644
--- a/connectivity/source/commontools/dbtools.cxx
+++ b/connectivity/source/commontools/dbtools.cxx
@@ -1139,7 +1139,7 @@ try
nKey = xFormats->addNew(sNewFormat, _rLocale);
}
- xNewProps->setPropertyValue(OMetaConnection::getPropMap().getNameByIndex(PROPERTY_ID_FORMATKEY), makeAny((sal_Int32)nKey));
+ xNewProps->setPropertyValue(OMetaConnection::getPropMap().getNameByIndex(PROPERTY_ID_FORMATKEY), makeAny(nKey));
}
// min-/max-Value
diff --git a/connectivity/source/drivers/calc/CTable.cxx b/connectivity/source/drivers/calc/CTable.cxx
index 7777318cb1ae..0d31b4b34cd9 100644
--- a/connectivity/source/drivers/calc/CTable.cxx
+++ b/connectivity/source/drivers/calc/CTable.cxx
@@ -732,8 +732,8 @@ bool OCalcTable::seekRow(IResultSetHelper::Movement eCursorPosition, sal_Int32 n
m_nFilePos = nNumberOfRecords;
break;
case IResultSetHelper::RELATIVE1:
- m_nFilePos = (((sal_Int32)m_nFilePos) + nOffset < 0) ? 0L
- : (sal_uInt32)(((sal_Int32)m_nFilePos) + nOffset);
+ m_nFilePos = (m_nFilePos + nOffset < 0) ? 0L
+ : (sal_uInt32)(m_nFilePos + nOffset);
break;
case IResultSetHelper::ABSOLUTE1:
case IResultSetHelper::BOOKMARK:
diff --git a/connectivity/source/drivers/dbase/DTable.cxx b/connectivity/source/drivers/dbase/DTable.cxx
index 167ff3ccf3db..ab223a886257 100644
--- a/connectivity/source/drivers/dbase/DTable.cxx
+++ b/connectivity/source/drivers/dbase/DTable.cxx
@@ -2592,7 +2592,7 @@ bool ODbaseTable::seekRow(IResultSetHelper::Movement eCursorPosition, sal_Int32
// prepare positioning:
OSL_ENSURE(m_pFileStream,"ODbaseTable::seekRow: FileStream is NULL!");
- sal_uInt32 nNumberOfRecords = (sal_uInt32)m_aHeader.db_anz;
+ sal_uInt32 nNumberOfRecords = m_aHeader.db_anz;
sal_uInt32 nTempPos = m_nFilePos;
m_nFilePos = nCurPos;
@@ -2612,8 +2612,8 @@ bool ODbaseTable::seekRow(IResultSetHelper::Movement eCursorPosition, sal_Int32
m_nFilePos = nNumberOfRecords;
break;
case IResultSetHelper::RELATIVE1:
- m_nFilePos = (((sal_Int32)m_nFilePos) + nOffset < 0) ? 0L
- : (sal_uInt32)(((sal_Int32)m_nFilePos) + nOffset);
+ m_nFilePos = (m_nFilePos + nOffset < 0) ? 0L
+ : (sal_uInt32)(m_nFilePos + nOffset);
break;
case IResultSetHelper::ABSOLUTE1:
case IResultSetHelper::BOOKMARK:
diff --git a/connectivity/source/drivers/file/FNoException.cxx b/connectivity/source/drivers/file/FNoException.cxx
index d1392bf7027a..299c37a27181 100644
--- a/connectivity/source/drivers/file/FNoException.cxx
+++ b/connectivity/source/drivers/file/FNoException.cxx
@@ -91,7 +91,7 @@ OKeyValue* OResultSet::GetOrderbyKeyValue(OValueRefRow& _rRow)
{
sal_uInt32 nBookmarkValue = std::abs((sal_Int32)(_rRow->get())[0]->getValue());
- OKeyValue* pKeyValue = OKeyValue::createKeyValue((sal_uInt32)nBookmarkValue);
+ OKeyValue* pKeyValue = OKeyValue::createKeyValue(nBookmarkValue);
std::vector<sal_Int32>::const_iterator aIter = m_aOrderbyColumnNumber.begin();
for (;aIter != m_aOrderbyColumnNumber.end(); ++aIter)
diff --git a/connectivity/source/drivers/file/FResultSetMetaData.cxx b/connectivity/source/drivers/file/FResultSetMetaData.cxx
index 070cd4492bc1..173bf318db78 100644
--- a/connectivity/source/drivers/file/FResultSetMetaData.cxx
+++ b/connectivity/source/drivers/file/FResultSetMetaData.cxx
@@ -51,7 +51,7 @@ OResultSetMetaData::~OResultSetMetaData()
void OResultSetMetaData::checkColumnIndex(sal_Int32 column)
{
- if(column <= 0 || column > (sal_Int32)(sal_Int32)m_xColumns->get().size())
+ if(column <= 0 || column > (sal_Int32)m_xColumns->get().size())
throwInvalidIndexException(*this);
}
diff --git a/connectivity/source/drivers/jdbc/DatabaseMetaData.cxx b/connectivity/source/drivers/jdbc/DatabaseMetaData.cxx
index 5697c71908d5..788da44fafd7 100644
--- a/connectivity/source/drivers/jdbc/DatabaseMetaData.cxx
+++ b/connectivity/source/drivers/jdbc/DatabaseMetaData.cxx
@@ -564,16 +564,16 @@ OUString java_sql_DatabaseMetaData::impl_callStringMethod( const char* _pMethodN
sal_Int32 java_sql_DatabaseMetaData::impl_callIntMethod_ThrowSQL(const char* _pMethodName, jmethodID& _inout_MethodID)
{
m_aLogger.log( LogLevel::FINEST, STR_LOG_META_DATA_METHOD, _pMethodName );
- sal_Int32 out( (sal_Int32)callIntMethod_ThrowSQL(_pMethodName,_inout_MethodID) );
- m_aLogger.log( LogLevel::FINEST, STR_LOG_META_DATA_RESULT, _pMethodName, (sal_Int32)out );
+ sal_Int32 out( callIntMethod_ThrowSQL(_pMethodName,_inout_MethodID) );
+ m_aLogger.log( LogLevel::FINEST, STR_LOG_META_DATA_RESULT, _pMethodName, out );
return out;
}
sal_Int32 java_sql_DatabaseMetaData::impl_callIntMethod_ThrowRuntime(const char* _pMethodName, jmethodID& _inout_MethodID)
{
m_aLogger.log( LogLevel::FINEST, STR_LOG_META_DATA_METHOD, _pMethodName );
- sal_Int32 out( (sal_Int32)callIntMethod_ThrowRuntime(_pMethodName,_inout_MethodID) );
- m_aLogger.log( LogLevel::FINEST, STR_LOG_META_DATA_RESULT, _pMethodName, (sal_Int32)out );
+ sal_Int32 out( callIntMethod_ThrowRuntime(_pMethodName,_inout_MethodID) );
+ m_aLogger.log( LogLevel::FINEST, STR_LOG_META_DATA_RESULT, _pMethodName, out );
return out;
}
diff --git a/connectivity/source/drivers/jdbc/JStatement.cxx b/connectivity/source/drivers/jdbc/JStatement.cxx
index ccee37942388..4f3e47679391 100644
--- a/connectivity/source/drivers/jdbc/JStatement.cxx
+++ b/connectivity/source/drivers/jdbc/JStatement.cxx
@@ -363,7 +363,7 @@ sal_Int32 SAL_CALL java_sql_Statement_Base::getUpdateCount( )
createStatement(t.pEnv);
static jmethodID mID(nullptr);
sal_Int32 out = callIntMethod_ThrowSQL("getUpdateCount", mID);
- m_aLogger.log( LogLevel::FINER, STR_LOG_UPDATE_COUNT, (sal_Int32)out );
+ m_aLogger.log( LogLevel::FINER, STR_LOG_UPDATE_COUNT, out );
return out;
}
@@ -519,7 +519,7 @@ void java_sql_Statement_Base::setResultSetConcurrency(sal_Int32 _par0)
{
::osl::MutexGuard aGuard( m_aMutex );
checkDisposed(java_sql_Statement_BASE::rBHelper.bDisposed);
- m_aLogger.log( LogLevel::FINE, STR_LOG_RESULT_SET_CONCURRENCY, (sal_Int32)_par0 );
+ m_aLogger.log( LogLevel::FINE, STR_LOG_RESULT_SET_CONCURRENCY, _par0 );
m_nResultSetConcurrency = _par0;
clearObject();
@@ -529,7 +529,7 @@ void java_sql_Statement_Base::setResultSetType(sal_Int32 _par0)
{
::osl::MutexGuard aGuard( m_aMutex );
checkDisposed(java_sql_Statement_BASE::rBHelper.bDisposed);
- m_aLogger.log( LogLevel::FINE, STR_LOG_RESULT_SET_TYPE, (sal_Int32)_par0 );
+ m_aLogger.log( LogLevel::FINE, STR_LOG_RESULT_SET_TYPE, _par0 );
m_nResultSetType = _par0;
clearObject();
@@ -539,7 +539,7 @@ void java_sql_Statement_Base::setFetchDirection(sal_Int32 _par0)
{
::osl::MutexGuard aGuard( m_aMutex );
checkDisposed(java_sql_Statement_BASE::rBHelper.bDisposed);
- m_aLogger.log( LogLevel::FINER, STR_LOG_FETCH_DIRECTION, (sal_Int32)_par0 );
+ m_aLogger.log( LogLevel::FINER, STR_LOG_FETCH_DIRECTION, _par0 );
SDBThreadAttach t; OSL_ENSURE(t.pEnv,"Java Enviroment geloescht worden!");
createStatement(t.pEnv);
static jmethodID mID(nullptr);
@@ -550,7 +550,7 @@ void java_sql_Statement_Base::setFetchSize(sal_Int32 _par0)
{
::osl::MutexGuard aGuard( m_aMutex );
checkDisposed(java_sql_Statement_BASE::rBHelper.bDisposed);
- m_aLogger.log( LogLevel::FINER, STR_LOG_FETCH_SIZE, (sal_Int32)_par0 );
+ m_aLogger.log( LogLevel::FINER, STR_LOG_FETCH_SIZE, _par0 );
SDBThreadAttach t; OSL_ENSURE(t.pEnv,"Java Enviroment geloescht worden!");
createStatement(t.pEnv);
diff --git a/connectivity/source/drivers/jdbc/PreparedStatement.cxx b/connectivity/source/drivers/jdbc/PreparedStatement.cxx
index ee084a45a6b1..6ded278caffa 100644
--- a/connectivity/source/drivers/jdbc/PreparedStatement.cxx
+++ b/connectivity/source/drivers/jdbc/PreparedStatement.cxx
@@ -540,9 +540,9 @@ void SAL_CALL java_sql_PreparedStatement::setBinaryStream( sal_Int32 parameterIn
// functions.html#wp22933>; work around that difference in a way
// that doesn't trigger loplugin:redundantcast
t.pEnv->SetByteArrayRegion(pByteArray,0,actualLength,aSeqData);
- args2[0].l = pByteArray;
- args2[1].i = 0;
- args2[2].i = (sal_Int32)actualLength;
+ args2[0].l = pByteArray;
+ args2[1].i = 0;
+ args2[2].i = actualLength;
// Java-Call
jclass aClass = t.pEnv->FindClass("java/io/ByteArrayInputStream");
@@ -556,7 +556,7 @@ void SAL_CALL java_sql_PreparedStatement::setBinaryStream( sal_Int32 parameterIn
jobject tempObj = nullptr;
if(mID2)
tempObj = t.pEnv->NewObjectA( aClass, mID2, args2 );
- t.pEnv->CallVoidMethod( object, mID, parameterIndex,tempObj,(sal_Int32)actualLength);
+ t.pEnv->CallVoidMethod( object, mID, parameterIndex,tempObj,actualLength);
// and clean up
t.pEnv->DeleteLocalRef(pByteArray);
t.pEnv->DeleteLocalRef(tempObj);
diff --git a/connectivity/source/drivers/jdbc/ResultSet.cxx b/connectivity/source/drivers/jdbc/ResultSet.cxx
index ec446f973c5e..490006b529f7 100644
--- a/connectivity/source/drivers/jdbc/ResultSet.cxx
+++ b/connectivity/source/drivers/jdbc/ResultSet.cxx
@@ -294,7 +294,7 @@ Any SAL_CALL java_sql_ResultSet::getObject( sal_Int32 columnIndex, const Referen
{
jvalue args[2];
// convert parameter
- args[0].i = (sal_Int32)columnIndex;
+ args[0].i = columnIndex;
args[1].l = convertTypeMapToJavaMap(t.pEnv,typeMap);
// initialize temporary Variable
// Java-Call
diff --git a/connectivity/source/drivers/mork/MResultSet.cxx b/connectivity/source/drivers/mork/MResultSet.cxx
index e0cfea8cb5f7..f7e29c8612b7 100644
--- a/connectivity/source/drivers/mork/MResultSet.cxx
+++ b/connectivity/source/drivers/mork/MResultSet.cxx
@@ -307,7 +307,7 @@ bool OResultSet::fetchRow(sal_Int32 cardNumber,bool bForceReload)
if (!bForceReload)
{
// Check whether we've already fetched the row...
- if ( !(m_aRow->get())[0].isNull() && (sal_Int32)(m_aRow->get())[0] == (sal_Int32)cardNumber )
+ if ( !(m_aRow->get())[0].isNull() && (sal_Int32)(m_aRow->get())[0] == cardNumber )
return true;
//Check whether the old row has been changed
if (cardNumber == m_nUpdatedRow)
@@ -323,7 +323,7 @@ bool OResultSet::fetchRow(sal_Int32 cardNumber,bool bForceReload)
if ( !validRow( cardNumber ) )
return false;
- (m_aRow->get())[0] = (sal_Int32)cardNumber;
+ (m_aRow->get())[0] = cardNumber;
sal_Int32 nCount = m_aColumnNames.getLength();
//m_RowStates = m_aQuery.getRowStates(cardNumber);
for( sal_Int32 i = 1; i <= nCount; i++ )
diff --git a/connectivity/source/drivers/mork/MResultSetMetaData.cxx b/connectivity/source/drivers/mork/MResultSetMetaData.cxx
index 707e51f4dd2c..59ed049d26b7 100644
--- a/connectivity/source/drivers/mork/MResultSetMetaData.cxx
+++ b/connectivity/source/drivers/mork/MResultSetMetaData.cxx
@@ -43,7 +43,7 @@ OResultSetMetaData::~OResultSetMetaData()
void OResultSetMetaData::checkColumnIndex(sal_Int32 column)
{
- if(column <= 0 || column > (sal_Int32)(sal_Int32)m_xColumns->get().size())
+ if(column <= 0 || column > (sal_Int32)m_xColumns->get().size())
throwInvalidIndexException(*this);
}
diff --git a/connectivity/source/drivers/postgresql/pq_preparedstatement.cxx b/connectivity/source/drivers/postgresql/pq_preparedstatement.cxx
index 8bcc770d7927..dfa72d49ed3a 100644
--- a/connectivity/source/drivers/postgresql/pq_preparedstatement.cxx
+++ b/connectivity/source/drivers/postgresql/pq_preparedstatement.cxx
@@ -455,7 +455,7 @@ void PreparedStatement::setInt( sal_Int32 parameterIndex, sal_Int32 x )
checkColumnIndex( parameterIndex );
OStringBuffer buf( 20 );
buf.append( "'" );
- buf.append( (sal_Int32) x );
+ buf.append( x );
buf.append( "'" );
m_vars[parameterIndex-1] = buf.makeStringAndClear();
}
@@ -467,7 +467,7 @@ void PreparedStatement::setLong( sal_Int32 parameterIndex, sal_Int64 x )
checkColumnIndex( parameterIndex );
OStringBuffer buf( 20 );
buf.append( "'" );
- buf.append( (sal_Int64) x );
+ buf.append( x );
buf.append( "'" );
m_vars[parameterIndex-1] = buf.makeStringAndClear();
}
diff --git a/connectivity/source/drivers/postgresql/pq_tools.cxx b/connectivity/source/drivers/postgresql/pq_tools.cxx
index f040b37086b5..3ab8d1d621d5 100644
--- a/connectivity/source/drivers/postgresql/pq_tools.cxx
+++ b/connectivity/source/drivers/postgresql/pq_tools.cxx
@@ -697,11 +697,11 @@ std::vector< sal_Int32 > parseIntArray( const OUString & str )
// printf( ">%s<\n" , OUStringToOString( str, RTL_TEXTENCODING_UTF8 ).getStr() );
for( sal_Int32 i = str.indexOf( ' ' ) ; i != -1 ; i = str.indexOf( ' ', start) )
{
- vec.push_back( (sal_Int32)rtl_ustr_toInt32( &str.pData->buffer[start], 10 ) );
+ vec.push_back( rtl_ustr_toInt32( &str.pData->buffer[start], 10 ) );
// printf( "found %d\n" , rtl_ustr_toInt32( &str.pData->buffer[start], 10 ));
start = i + 1;
}
- vec.push_back( (sal_Int32)rtl_ustr_toInt32( &str.pData->buffer[start], 10 ) );
+ vec.push_back( rtl_ustr_toInt32( &str.pData->buffer[start], 10 ) );
// printf( "found %d\n" , rtl_ustr_toInt32( &str.pData->buffer[start], 10 ));
return vec;
}
diff --git a/cppuhelper/source/propshlp.cxx b/cppuhelper/source/propshlp.cxx
index bc758f95cfc5..5533e9857477 100644
--- a/cppuhelper/source/propshlp.cxx
+++ b/cppuhelper/source/propshlp.cxx
@@ -312,7 +312,7 @@ void OPropertySetHelper::addPropertyChangeListener(
}
// add the change listener to the helper container
- aBoundLC.addInterface( (sal_Int32)nHandle, rxListener );
+ aBoundLC.addInterface( nHandle, rxListener );
}
else
// add the change listener to the helper container
@@ -343,7 +343,7 @@ void OPropertySetHelper::removePropertyChangeListener(
if( nHandle == -1 )
// property not known throw exception
throw UnknownPropertyException();
- aBoundLC.removeInterface( (sal_Int32)nHandle, rxListener );
+ aBoundLC.removeInterface( nHandle, rxListener );
}
else {
// remove the change listener to the helper container
@@ -387,7 +387,7 @@ void OPropertySetHelper::addVetoableChangeListener(
return;
}
// add the vetoable listener to the helper container
- aVetoableLC.addInterface( (sal_Int32)nHandle, rxListener );
+ aVetoableLC.addInterface( nHandle, rxListener );
}
else
// add the vetoable listener to the helper container
@@ -419,7 +419,7 @@ void OPropertySetHelper::removeVetoableChangeListener(
throw UnknownPropertyException();
}
// remove the vetoable listener to the helper container
- aVetoableLC.removeInterface( (sal_Int32)nHandle, rxListener );
+ aVetoableLC.removeInterface( nHandle, rxListener );
}
else
// add the vetoable listener to the helper container
diff --git a/cui/source/options/optinet2.cxx b/cui/source/options/optinet2.cxx
index 81e2698187b7..5c9e357e84d8 100644
--- a/cui/source/options/optinet2.cxx
+++ b/cui/source/options/optinet2.cxx
@@ -421,8 +421,7 @@ bool SvxProxyTabPage::FillItemSet(SfxItemSet* )
return true;
}
- xPropertySet->setPropertyValue(g_aProxyModePN,
- Any((sal_Int32) nSelPos));
+ xPropertySet->setPropertyValue(g_aProxyModePN, Any(nSelPos));
bModified = true;
}
diff --git a/cui/source/tabpages/swpossizetabpage.cxx b/cui/source/tabpages/swpossizetabpage.cxx
index e1e3d5852589..2a4deffed663 100644
--- a/cui/source/tabpages/swpossizetabpage.cxx
+++ b/cui/source/tabpages/swpossizetabpage.cxx
@@ -911,10 +911,8 @@ bool SvxSwPosSizeTabPage::FillItemSet( SfxItemSet* rSet)
{
sal_uInt32 nWidth = static_cast<sal_uInt32>(m_pWidthMF->Denormalize(m_pWidthMF->GetValue(FUNIT_TWIP)));
sal_uInt32 nHeight = static_cast<sal_uInt32>(m_pHeightMF->Denormalize(m_pHeightMF->GetValue(FUNIT_TWIP)));
- rSet->Put( SfxUInt32Item( GetWhich( SID_ATTR_TRANSFORM_WIDTH ),
- (sal_uInt32) nWidth ) );
- rSet->Put( SfxUInt32Item( GetWhich( SID_ATTR_TRANSFORM_HEIGHT ),
- (sal_uInt32) nHeight ) );
+ rSet->Put( SfxUInt32Item( GetWhich( SID_ATTR_TRANSFORM_WIDTH ), nWidth ) );
+ rSet->Put( SfxUInt32Item( GetWhich( SID_ATTR_TRANSFORM_HEIGHT ), nHeight ) );
//this item is required by SdrEditView::SetGeoAttrToMarked()
rSet->Put( SfxAllEnumItem( GetWhich( SID_ATTR_TRANSFORM_SIZE_POINT ), (sal_uInt16)RectPoint::LT ) );
diff --git a/cui/source/tabpages/tabstpge.cxx b/cui/source/tabpages/tabstpge.cxx
index 6b7842618acf..f6f42f4312fd 100644
--- a/cui/source/tabpages/tabstpge.cxx
+++ b/cui/source/tabpages/tabstpge.cxx
@@ -433,7 +433,7 @@ void SvxTabulatorTabPage::SetFillAndTabType_Impl()
pTypeBtn = m_pDezTab;
m_pDezChar->Enable();
m_pDezCharLabel->Enable();
- m_pDezChar->SetText( OUString( (sal_Unicode)aAktTab.GetDecimal() ) );
+ m_pDezChar->SetText( OUString( aAktTab.GetDecimal() ) );
}
else if ( aAktTab.GetAdjustment() == SvxTabAdjust::Center )
pTypeBtn = m_pCenterTab;
@@ -456,7 +456,7 @@ void SvxTabulatorTabPage::SetFillAndTabType_Impl()
{
pFillBtn = m_pFillSpecial;
m_pFillChar->Enable();
- m_pFillChar->SetText( OUString( (sal_Unicode)aAktTab.GetFill() ) );
+ m_pFillChar->SetText( OUString( aAktTab.GetFill() ) );
}
pFillBtn->Check();
}
@@ -587,7 +587,7 @@ IMPL_LINK( SvxTabulatorTabPage, TabTypeCheckHdl_Impl, Button *, pBox, void )
eAdj = SvxTabAdjust::Decimal;
m_pDezChar->Enable();
m_pDezCharLabel->Enable();
- m_pDezChar->SetText( OUString( (sal_Unicode)aAktTab.GetDecimal() ) );
+ m_pDezChar->SetText( OUString( aAktTab.GetDecimal() ) );
}
aAktTab.GetAdjustment() = eAdj;
diff --git a/dbaccess/source/filter/xml/xmlDataSourceSetting.cxx b/dbaccess/source/filter/xml/xmlDataSourceSetting.cxx
index c153b7a71253..45491d251667 100644
--- a/dbaccess/source/filter/xml/xmlDataSourceSetting.cxx
+++ b/dbaccess/source/filter/xml/xmlDataSourceSetting.cxx
@@ -198,7 +198,7 @@ Any OXMLDataSourceSetting::convertString(const css::uno::Type& _rExpectedType, c
if (TypeClass_SHORT == _rExpectedType.getTypeClass())
aReturn <<= (sal_Int16)nValue;
else
- aReturn <<= (sal_Int32)nValue;
+ aReturn <<= nValue;
break;
}
case TypeClass_HYPER:
diff --git a/dbaccess/source/ui/browser/formadapter.cxx b/dbaccess/source/ui/browser/formadapter.cxx
index 083f2f536420..6b4650ef04fb 100644
--- a/dbaccess/source/ui/browser/formadapter.cxx
+++ b/dbaccess/source/ui/browser/formadapter.cxx
@@ -1586,7 +1586,7 @@ void SAL_CALL SbaXFormAdapter::replaceByIndex(sal_Int32 _rIndex, const Any& Elem
// notify container listeners
css::container::ContainerEvent aEvt;
aEvt.Source = *this;
- aEvt.Accessor <<= (sal_Int32)_rIndex;
+ aEvt.Accessor <<= _rIndex;
aEvt.Element <<= xElement;
aEvt.ReplacedElement <<= xOld;
diff --git a/dbaccess/source/ui/querydesign/TableFieldDescription.cxx b/dbaccess/source/ui/querydesign/TableFieldDescription.cxx
index 20298d11006b..53ff10d9be88 100644
--- a/dbaccess/source/ui/querydesign/TableFieldDescription.cxx
+++ b/dbaccess/source/ui/querydesign/TableFieldDescription.cxx
@@ -171,7 +171,7 @@ void OTableFieldDesc::Save( ::comphelper::NamedValueCollection& o_rSettings, con
o_rSettings.put( "FieldAlias", m_aFieldAlias );
o_rSettings.put( "FunctionName", m_aFunctionName );
o_rSettings.put( "DataType", m_eDataType );
- o_rSettings.put( "FunctionType", (sal_Int32)m_eFunctionType );
+ o_rSettings.put( "FunctionType", m_eFunctionType );
o_rSettings.put( "FieldType", (sal_Int32)m_eFieldType );
o_rSettings.put( "OrderDir", (sal_Int32)m_eOrderDir );
o_rSettings.put( "ColWidth", m_nColWidth );
diff --git a/drawinglayer/source/primitive2d/sceneprimitive2d.cxx b/drawinglayer/source/primitive2d/sceneprimitive2d.cxx
index bbf6774cf663..030c6985f321 100644
--- a/drawinglayer/source/primitive2d/sceneprimitive2d.cxx
+++ b/drawinglayer/source/primitive2d/sceneprimitive2d.cxx
@@ -361,8 +361,8 @@ namespace drawinglayer
const double fFullViewSizeY((rViewInformation.getObjectToViewTransformation() * basegfx::B2DVector(0.0, fLogicY)).getLength());
// generate RasterWidth and RasterHeight for visible part
- const sal_Int32 nRasterWidth((sal_Int32)basegfx::fround(fFullViewSizeX * aUnitVisibleRange.getWidth()) + 1);
- const sal_Int32 nRasterHeight((sal_Int32)basegfx::fround(fFullViewSizeY * aUnitVisibleRange.getHeight()) + 1);
+ const sal_Int32 nRasterWidth(basegfx::fround(fFullViewSizeX * aUnitVisibleRange.getWidth()) + 1);
+ const sal_Int32 nRasterHeight(basegfx::fround(fFullViewSizeY * aUnitVisibleRange.getHeight()) + 1);
if(nRasterWidth && nRasterHeight)
{
diff --git a/editeng/source/accessibility/AccessibleEditableTextPara.cxx b/editeng/source/accessibility/AccessibleEditableTextPara.cxx
index 50bb53ba5d43..c1b6f30202ef 100644
--- a/editeng/source/accessibility/AccessibleEditableTextPara.cxx
+++ b/editeng/source/accessibility/AccessibleEditableTextPara.cxx
@@ -788,7 +788,7 @@ namespace accessibility
}
// relation CONTENT_FLOWS_TO
- if ( (nMyParaIndex + 1) < (sal_Int32)mpParaManager->GetNum() &&
+ if ( (nMyParaIndex + 1) < mpParaManager->GetNum() &&
mpParaManager->IsReferencable( nMyParaIndex + 1 ) )
{
uno::Sequence<uno::Reference<XInterface> > aSequence
diff --git a/editeng/source/editeng/editdoc.cxx b/editeng/source/editeng/editdoc.cxx
index 2b2356d07745..5cb51b1ea647 100644
--- a/editeng/source/editeng/editdoc.cxx
+++ b/editeng/source/editeng/editdoc.cxx
@@ -631,7 +631,7 @@ sal_Int32 ParaPortion::GetLineNumber( sal_Int32 nIndex ) const
for ( sal_Int32 nLine = 0; nLine < aLineList.Count(); nLine++ )
{
if ( aLineList[nLine].IsIn( nIndex ) )
- return (sal_Int32)nLine;
+ return nLine;
}
// Then it should be at the end of the last line!
diff --git a/editeng/source/editeng/editview.cxx b/editeng/source/editeng/editview.cxx
index 9f55c2cf0809..7b6ec40254cf 100644
--- a/editeng/source/editeng/editview.cxx
+++ b/editeng/source/editeng/editview.cxx
@@ -1183,7 +1183,7 @@ void EditView::SetInvalidateMore( sal_uInt16 nPixel )
sal_uInt16 EditView::GetInvalidateMore() const
{
- return (sal_uInt16)pImpEditView->GetInvalidateMore();
+ return pImpEditView->GetInvalidateMore();
}
static void ChangeFontSizeImpl( EditView* pEditView, bool bGrow, const ESelection& rSel, const FontList* pFontList )
diff --git a/editeng/source/editeng/impedit2.cxx b/editeng/source/editeng/impedit2.cxx
index 37cd711b5bad..d925b2c8a0cc 100644
--- a/editeng/source/editeng/impedit2.cxx
+++ b/editeng/source/editeng/impedit2.cxx
@@ -1963,7 +1963,7 @@ bool ImpEditEngine::HasDifferentRTLLevels( const ContentNode* pNode )
bool bHasDifferentRTLLevels = false;
sal_uInt16 nRTLLevel = IsRightToLeft( nPara ) ? 1 : 0;
- for ( sal_Int32 n = 0; n < (sal_Int32)pParaPortion->GetTextPortions().Count(); n++ )
+ for ( sal_Int32 n = 0; n < pParaPortion->GetTextPortions().Count(); n++ )
{
const TextPortion& rTextPortion = pParaPortion->GetTextPortions()[n];
if ( rTextPortion.GetRightToLeftLevel() != nRTLLevel )
@@ -3075,7 +3075,7 @@ sal_uInt32 ImpEditEngine::CalcTextWidth( bool bIgnoreExtraSpace )
// On the lines of the paragraph ...
- sal_Int32 nLines = (sal_Int32)pPortion->GetLines().Count();
+ sal_Int32 nLines = pPortion->GetLines().Count();
for ( sal_Int32 nLine = 0; nLine < nLines; nLine++ )
{
EditLine& rLine = pPortion->GetLines()[nLine];
diff --git a/editeng/source/editeng/impedit3.cxx b/editeng/source/editeng/impedit3.cxx
index 10ae5407dd51..c45f239d3885 100644
--- a/editeng/source/editeng/impedit3.cxx
+++ b/editeng/source/editeng/impedit3.cxx
@@ -2401,7 +2401,7 @@ void ImpEditEngine::CreateTextPortions( ParaPortion* pParaPortion, sal_Int32& rS
sal_Int32 nPortionStart = 0;
sal_Int32 nInvPortion = 0;
sal_Int32 nP;
- for ( nP = 0; nP < (sal_Int32)pParaPortion->GetTextPortions().Count(); nP++ )
+ for ( nP = 0; nP < pParaPortion->GetTextPortions().Count(); nP++ )
{
const TextPortion& rTmpPortion = pParaPortion->GetTextPortions()[nP];
nPortionStart = nPortionStart + rTmpPortion.GetLen();
@@ -2462,7 +2462,7 @@ void ImpEditEngine::RecalcTextPortion( ParaPortion* pParaPortion, sal_Int32 nSta
// A blank portion may be here, if the paragraph was empty,
// or if a line was created by a hard line break.
- if ( ( nNewPortionPos < (sal_Int32)pParaPortion->GetTextPortions().Count() ) &&
+ if ( ( nNewPortionPos < pParaPortion->GetTextPortions().Count() ) &&
!pParaPortion->GetTextPortions()[nNewPortionPos].GetLen() )
{
TextPortion& rTP = pParaPortion->GetTextPortions()[nNewPortionPos];
@@ -3454,7 +3454,7 @@ void ImpEditEngine::Paint( OutputDevice* pOutDev, Rectangle aClipRect, Point aSt
aTmpFont.SetPropr( 100 );
aTmpFont.SetPhysFont( pOutDev );
OUStringBuffer aBlanks;
- comphelper::string::padToLength( aBlanks, (sal_Int32) nTextLen, ' ' );
+ comphelper::string::padToLength( aBlanks, nTextLen, ' ' );
Point aUnderlinePos( aOutPos );
if ( nOrientation )
aUnderlinePos = lcl_ImplCalcRotatedPos( aTmpPos, aOrigin, nSin, nCos );
@@ -4203,7 +4203,7 @@ LanguageType ImpEditEngine::ImplCalcDigitLang(LanguageType eCurLang) const
else if ( SvtCTLOptions::NUMERALS_ARABIC == nCTLTextNumerals )
eLang = LANGUAGE_ENGLISH;
else if ( SvtCTLOptions::NUMERALS_SYSTEM == nCTLTextNumerals )
- eLang = (LanguageType) Application::GetSettings().GetLanguageTag().getLanguageType();
+ eLang = Application::GetSettings().GetLanguageTag().getLanguageType();
return eLang;
}
@@ -4271,7 +4271,7 @@ void ImpEditEngine::ImplInitLayoutMode( OutputDevice* pOutDev, sal_Int32 nPara,
// #114278# Also setting up digit language from Svt options
// (cannot reliably inherit the outdev's setting)
- LanguageType eLang = (LanguageType) Application::GetSettings().GetLanguageTag().getLanguageType();
+ LanguageType eLang = Application::GetSettings().GetLanguageTag().getLanguageType();
ImplInitDigitMode( pOutDev, eLang );
}
diff --git a/editeng/source/items/bulitem.cxx b/editeng/source/items/bulitem.cxx
index 1e2e6a81a62b..c90634daf52f 100644
--- a/editeng/source/items/bulitem.cxx
+++ b/editeng/source/items/bulitem.cxx
@@ -36,7 +36,7 @@ void SvxBulletItem::StoreFont( SvStream& rStream, const vcl::Font& rFont )
WriteColor( rStream, rFont.GetColor() );
nTemp = (sal_uInt16)rFont.GetFamilyType(); rStream.WriteUInt16( nTemp );
- nTemp = (sal_uInt16)GetSOStoreTextEncoding((rtl_TextEncoding)rFont.GetCharSet());
+ nTemp = (sal_uInt16)GetSOStoreTextEncoding(rFont.GetCharSet());
rStream.WriteUInt16( nTemp );
nTemp = (sal_uInt16)rFont.GetPitch(); rStream.WriteUInt16( nTemp );
diff --git a/editeng/source/items/textitem.cxx b/editeng/source/items/textitem.cxx
index ab5cd092dd92..a9d2777428e1 100644
--- a/editeng/source/items/textitem.cxx
+++ b/editeng/source/items/textitem.cxx
@@ -2134,7 +2134,7 @@ bool SvxCaseMapItem::QueryValue( uno::Any& rVal, sal_uInt8 /*nMemberId*/ ) const
case SvxCaseMap::SmallCaps: nRet = style::CaseMap::SMALLCAPS; break;
default: break;
}
- rVal <<= (sal_Int16)(nRet);
+ rVal <<= nRet;
return true;
}
@@ -3401,7 +3401,7 @@ void GetDefaultFonts( SvxFontItem& rLatin, SvxFontItem& rAsian, SvxFontItem& rCo
bool SvxRsidItem::QueryValue( uno::Any& rVal, sal_uInt8 ) const
{
- rVal <<= ( (sal_uInt32)GetValue() );
+ rVal <<= GetValue();
return true;
}
diff --git a/editeng/source/misc/unolingu.cxx b/editeng/source/misc/unolingu.cxx
index e306551ee4d5..c87953bd37d0 100644
--- a/editeng/source/misc/unolingu.cxx
+++ b/editeng/source/misc/unolingu.cxx
@@ -703,7 +703,7 @@ SvxAlternativeSpelling SvxGetAltSpelling(
++nR;
aRes.aReplacement = aAltWord.copy( nL, nAltLen - nL - nR );
- aRes.nChangedPos = (sal_Int16) nL;
+ aRes.nChangedPos = nL;
aRes.nChangedLength = nLen - nL - nR;
aRes.bIsAltSpelling = true;
aRes.xHyphWord = rHyphWord;
diff --git a/extensions/source/propctrlr/formcomponenthandler.cxx b/extensions/source/propctrlr/formcomponenthandler.cxx
index 8588ae6acc57..c2806d2d4bfc 100644
--- a/extensions/source/propctrlr/formcomponenthandler.cxx
+++ b/extensions/source/propctrlr/formcomponenthandler.cxx
@@ -2918,7 +2918,7 @@ namespace pcr
aColor = aColorDlg.GetColor();
nColor = aColor.GetColor();
- _out_rNewValue <<= (sal_Int32)nColor;
+ _out_rNewValue <<= nColor;
return true;
}
diff --git a/extensions/source/propctrlr/formmetadata.cxx b/extensions/source/propctrlr/formmetadata.cxx
index f37604f2d78d..21f01ffb4a39 100644
--- a/extensions/source/propctrlr/formmetadata.cxx
+++ b/extensions/source/propctrlr/formmetadata.cxx
@@ -611,7 +611,7 @@ namespace pcr
break;
default:
- _out_rValue <<= (sal_Int32)nPos;
+ _out_rValue <<= nPos;
break;
}
}
diff --git a/filter/source/graphicfilter/eps/eps.cxx b/filter/source/graphicfilter/eps/eps.cxx
index 707c50e1cd79..33bf466a2972 100644
--- a/filter/source/graphicfilter/eps/eps.cxx
+++ b/filter/source/graphicfilter/eps/eps.cxx
@@ -2167,14 +2167,14 @@ void PSWriter::ImplWriteColor( sal_uLong nMode )
{
// writes the Color (grayscale) as a Number from 0.000 up to 1.000
- ImplWriteF( 1000 * ( (sal_uInt8)aColor.GetRed() * 77 + (sal_uInt8)aColor.GetGreen() * 151 +
- (sal_uInt8)aColor.GetBlue() * 28 + 1 ) / 65536, 3, nMode );
+ ImplWriteF( 1000 * ( aColor.GetRed() * 77 + aColor.GetGreen() * 151 +
+ aColor.GetBlue() * 28 + 1 ) / 65536, 3, nMode );
}
else
{
- ImplWriteB1 ( (sal_uInt8)aColor.GetRed() );
- ImplWriteB1 ( (sal_uInt8)aColor.GetGreen() );
- ImplWriteB1 ( (sal_uInt8)aColor.GetBlue() );
+ ImplWriteB1 ( aColor.GetRed() );
+ ImplWriteB1 ( aColor.GetGreen() );
+ ImplWriteB1 ( aColor.GetBlue() );
}
mpPS->WriteCharPtr( "c" ); // ( c is defined as setrgbcolor or setgray )
ImplExecMode( nMode );
diff --git a/filter/source/graphicfilter/ipict/ipict.cxx b/filter/source/graphicfilter/ipict/ipict.cxx
index 6ab4b7f7dc78..dd5024df94e1 100644
--- a/filter/source/graphicfilter/ipict/ipict.cxx
+++ b/filter/source/graphicfilter/ipict/ipict.cxx
@@ -1105,7 +1105,7 @@ sal_uLong PictReader::ReadPixMapEtc( Bitmap &rBitmap, bool bBaseAddr, bool bColo
else
{
pPict->ReadUChar( nByteCountAsByte );
- nByteCount = (sal_uInt8)nByteCountAsByte;
+ nByteCount = nByteCountAsByte;
nByteCount++;
}
size_t i = 0;
diff --git a/filter/source/graphicfilter/ipsd/ipsd.cxx b/filter/source/graphicfilter/ipsd/ipsd.cxx
index 986ebbb9a636..cfb2c4ef5bab 100644
--- a/filter/source/graphicfilter/ipsd/ipsd.cxx
+++ b/filter/source/graphicfilter/ipsd/ipsd.cxx
@@ -627,13 +627,13 @@ bool PSDReader::ImplReadBody()
for ( sal_uInt16 i = 0; i < ( -nRunCount + 1 ); i++ )
{
- nBlack = (sal_uInt8)mpReadAcc->GetPixel( nY, nX ).GetRed() + nDat;
+ nBlack = mpReadAcc->GetPixel( nY, nX ).GetRed() + nDat;
if ( nBlack > nBlackMax )
nBlackMax = nBlack;
- nBlack = (sal_uInt8)mpReadAcc->GetPixel( nY, nX ).GetGreen() + nDat;
+ nBlack = mpReadAcc->GetPixel( nY, nX ).GetGreen() + nDat;
if ( nBlack > nBlackMax )
nBlackMax = nBlack;
- nBlack = (sal_uInt8)mpReadAcc->GetPixel( nY, nX ).GetBlue() + nDat;
+ nBlack = mpReadAcc->GetPixel( nY, nX ).GetBlue() + nDat;
if ( nBlack > nBlackMax )
nBlackMax = nBlack;
pBlack[ nX + nY * mpFileHeader->nColumns ] = nDat ^ 0xff;
@@ -654,13 +654,13 @@ bool PSDReader::ImplReadBody()
if ( mpFileHeader->nDepth == 16 ) // 16 bit depth is to be skipped
m_rPSD.ReadUChar( nDummy );
- nBlack = (sal_uInt8)mpReadAcc->GetPixel( nY, nX ).GetRed() + nDat;
+ nBlack = mpReadAcc->GetPixel( nY, nX ).GetRed() + nDat;
if ( nBlack > nBlackMax )
nBlackMax = nBlack;
- nBlack = (sal_uInt8)mpReadAcc->GetPixel( nY, nX ).GetGreen() + nDat;
+ nBlack = mpReadAcc->GetPixel( nY, nX ).GetGreen() + nDat;
if ( nBlack > nBlackMax )
nBlackMax = nBlack;
- nBlack = (sal_uInt8)mpReadAcc->GetPixel( nY, nX ).GetBlue() + nDat;
+ nBlack = mpReadAcc->GetPixel( nY, nX ).GetBlue() + nDat;
if ( nBlack > nBlackMax )
nBlackMax = nBlack;
pBlack[ nX + nY * mpFileHeader->nColumns ] = nDat ^ 0xff;
diff --git a/filter/source/graphicfilter/itiff/itiff.cxx b/filter/source/graphicfilter/itiff/itiff.cxx
index 37ab726a7545..4c4b10a3b825 100644
--- a/filter/source/graphicfilter/itiff/itiff.cxx
+++ b/filter/source/graphicfilter/itiff/itiff.cxx
@@ -939,7 +939,7 @@ bool TIFFReader::ConvertScanline(sal_Int32 nY)
sal_uInt8 nLast = 0;
for (sal_Int32 nx = 0; nx < nImageWidth; ++nx)
{
- nLast += nx == 0 ? BYTESWAP( (sal_uInt8)*pt++ ) : *pt++;
+ nLast += nx == 0 ? BYTESWAP( *pt++ ) : *pt++;
pAcc->SetPixelIndex( nY, nx, nLast );
}
}
diff --git a/filter/source/msfilter/eschesdo.cxx b/filter/source/msfilter/eschesdo.cxx
index bbaeca550644..79b8e01a48b5 100644
--- a/filter/source/msfilter/eschesdo.cxx
+++ b/filter/source/msfilter/eschesdo.cxx
@@ -298,8 +298,7 @@ sal_uInt32 ImplEESdrWriter::ImplWriteShape( ImplEESdrObject& rObj,
else if ( rObj.GetType() == "drawing.Rectangle" )
{
mpEscherEx->OpenContainer( ESCHER_SpContainer );
- sal_Int32 nRadius = (sal_Int32)rObj.ImplGetInt32PropertyValue(
- OUString( "CornerRadius" ));
+ sal_Int32 nRadius = rObj.ImplGetInt32PropertyValue("CornerRadius");
if( nRadius )
{
nRadius = ImplMapSize( Size( nRadius, 0 )).Width();
diff --git a/filter/source/msfilter/svdfppt.cxx b/filter/source/msfilter/svdfppt.cxx
index 92e5f8fa1be5..d6fb2f6cc3c0 100644
--- a/filter/source/msfilter/svdfppt.cxx
+++ b/filter/source/msfilter/svdfppt.cxx
@@ -2425,7 +2425,7 @@ sal_uInt32 SdrPowerPointImport::GetAktPageId()
{
PptSlidePersistList* pList = GetPageList( eAktPageKind );
if ( pList && nAktPageNum < pList->size() )
- return (*pList)[ (sal_uInt16)nAktPageNum ].aPersistAtom.nSlideId;
+ return (*pList)[ nAktPageNum ].aPersistAtom.nSlideId;
return 0;
}
@@ -3763,8 +3763,8 @@ void PPTNumberFormatCreator::ImplGetNumberFormat( SdrPowerPointImport& rManager,
rNumberFormat.SetBulletChar( nBuChar );
rNumberFormat.SetBulletRelSize( (sal_uInt16)nBulletHeight );
rNumberFormat.SetBulletColor( aCol );
- sal_uInt16 nAbsLSpace = (sal_uInt16)( ( (sal_uInt32)nTextOfs * 2540 ) / 576 );
- sal_uInt16 nFirstLineOffset = nAbsLSpace - (sal_uInt16)( ( (sal_uInt32)nBulletOfs * 2540 ) / 576 );
+ sal_uInt16 nAbsLSpace = (sal_uInt16)( ( nTextOfs * 2540 ) / 576 );
+ sal_uInt16 nFirstLineOffset = nAbsLSpace - (sal_uInt16)( ( nBulletOfs * 2540 ) / 576 );
rNumberFormat.SetAbsLSpace( nAbsLSpace );
rNumberFormat.SetFirstLineOffset( -nFirstLineOffset );
}
@@ -6234,8 +6234,8 @@ void PPTParagraphObj::ApplyTo( SfxItemSet& rSet, boost::optional< sal_Int16 >&
if ( !nIsBullet2 )
{
SvxLRSpaceItem aLRSpaceItem( EE_PARA_LRSPACE );
- sal_uInt16 nAbsLSpace = (sal_uInt16)( ( (sal_uInt32)_nTextOfs * 2540 ) / 576 );
- sal_uInt16 nFirstLineOffset = nAbsLSpace - (sal_uInt16)( ( (sal_uInt32)_nBulletOfs * 2540 ) / 576 );
+ sal_uInt16 nAbsLSpace = (sal_uInt16)( ( _nTextOfs * 2540 ) / 576 );
+ sal_uInt16 nFirstLineOffset = nAbsLSpace - (sal_uInt16)( ( _nBulletOfs * 2540 ) / 576 );
aLRSpaceItem.SetLeft( nAbsLSpace );
aLRSpaceItem.SetTextFirstLineOfstValue( -nFirstLineOffset );
rSet.Put( aLRSpaceItem );
diff --git a/filter/source/pdf/impdialog.cxx b/filter/source/pdf/impdialog.cxx
index 6ffa9f0f3d91..42af810c9113 100644
--- a/filter/source/pdf/impdialog.cxx
+++ b/filter/source/pdf/impdialog.cxx
@@ -732,7 +732,7 @@ void ImpPDFTabGeneralPage::GetFilterConfigItem( ImpPDFTabDialog* paParent )
* FIXME: the entries are only implicitly defined by the resource file. Should there
* ever be an additional form submit format this could get invalid.
*/
- paParent->mnFormsType = (sal_Int32) mpLbFormsFormat->GetSelectEntryPos();
+ paParent->mnFormsType = mpLbFormsFormat->GetSelectEntryPos();
paParent->mbAllowDuplicateFieldNames = mpCbAllowDuplicateFieldNames->IsChecked();
}
diff --git a/filter/source/svg/svgwriter.cxx b/filter/source/svg/svgwriter.cxx
index 22b3f1f8fe6e..1efa2f50afb2 100644
--- a/filter/source/svg/svgwriter.cxx
+++ b/filter/source/svg/svgwriter.cxx
@@ -1015,7 +1015,7 @@ bool SVGTextWriter::nextParagraph()
rProp.Value >>= sValue;
if( !sValue.isEmpty() )
{
- cBullet = (sal_Unicode)sValue[0];
+ cBullet = sValue[0];
}
}
}
diff --git a/filter/source/xsltdialog/xmlfiltertabdialog.cxx b/filter/source/xsltdialog/xmlfiltertabdialog.cxx
index 917cb2cf5de1..e3d5e9bcad94 100644
--- a/filter/source/xsltdialog/xmlfiltertabdialog.cxx
+++ b/filter/source/xsltdialog/xmlfiltertabdialog.cxx
@@ -247,7 +247,7 @@ bool XMLFilterTabDialog::onOk()
if( 0 != nErrorId )
{
- m_pTabCtrl->SetCurPageId((sal_uInt16)nErrorPage);
+ m_pTabCtrl->SetCurPageId(nErrorPage);
ActivatePageHdl(nullptr, m_pTabCtrl);
ResId aResId( nErrorId, mrResMgr );
diff --git a/forms/source/component/Columns.cxx b/forms/source/component/Columns.cxx
index c221024dd533..a3ea165dd123 100644
--- a/forms/source/component/Columns.cxx
+++ b/forms/source/component/Columns.cxx
@@ -539,7 +539,7 @@ void SAL_CALL OGridColumn::read(const Reference<XObjectInputStream>& _rxInStream
if (nAnyMask & WIDTH)
{
sal_Int32 nValue = _rxInStream->readLong();
- m_aWidth <<= (sal_Int32)nValue;
+ m_aWidth <<= nValue;
}
if (nAnyMask & ALIGN)
diff --git a/forms/source/component/DatabaseForm.cxx b/forms/source/component/DatabaseForm.cxx
index a98e62422f0e..b8e25b4e2f11 100644
--- a/forms/source/component/DatabaseForm.cxx
+++ b/forms/source/component/DatabaseForm.cxx
@@ -1165,7 +1165,7 @@ bool ODatabaseForm::executeRowSet(::osl::ResettableMutexGuard& _rClearForNotifie
else
nConcurrency = ResultSetConcurrency::READ_ONLY;
- m_xAggregateSet->setPropertyValue( PROPERTY_RESULTSET_CONCURRENCY, makeAny( (sal_Int32)nConcurrency ) );
+ m_xAggregateSet->setPropertyValue( PROPERTY_RESULTSET_CONCURRENCY, makeAny( nConcurrency ) );
m_xAggregateSet->setPropertyValue( PROPERTY_RESULTSET_TYPE, makeAny( (sal_Int32)ResultSetType::SCROLL_SENSITIVE ) );
bool bSuccess = false;
diff --git a/forms/source/component/EditBase.cxx b/forms/source/component/EditBase.cxx
index aedecc889582..261efa16073c 100644
--- a/forms/source/component/EditBase.cxx
+++ b/forms/source/component/EditBase.cxx
@@ -184,7 +184,7 @@ void OEditBaseModel::read(const Reference<XObjectInputStream>& _rxInStream)
if ((nAnyMask & DEFAULT_LONG) == DEFAULT_LONG)
{
sal_Int32 nValue = _rxInStream->readLong();
- m_aDefault <<= (sal_Int32)nValue;
+ m_aDefault <<= nValue;
}
else if ((nAnyMask & DEFAULT_DOUBLE) == DEFAULT_DOUBLE)
{
diff --git a/forms/source/component/FormattedField.cxx b/forms/source/component/FormattedField.cxx
index df531277fe5b..67c0a2b11d51 100644
--- a/forms/source/component/FormattedField.cxx
+++ b/forms/source/component/FormattedField.cxx
@@ -793,7 +793,7 @@ void OFormattedModel::read(const Reference<XObjectInputStream>& _rxInStream)
if ((nKey != -1) && m_xAggregateSet.is())
{
m_xAggregateSet->setPropertyValue(PROPERTY_FORMATSSUPPLIER, makeAny(xSupplier));
- m_xAggregateSet->setPropertyValue(PROPERTY_FORMATKEY, makeAny((sal_Int32)nKey));
+ m_xAggregateSet->setPropertyValue(PROPERTY_FORMATKEY, makeAny(nKey));
}
else
{
diff --git a/forms/source/component/Grid.cxx b/forms/source/component/Grid.cxx
index c8128f3e8d9e..c2bb083b7f9c 100644
--- a/forms/source/component/Grid.cxx
+++ b/forms/source/component/Grid.cxx
@@ -928,7 +928,7 @@ void OGridControlModel::read(const Reference<XObjectInputStream>& _rxInStream)
if (nAnyMask & ROWHEIGHT)
{
sal_Int32 nValue = _rxInStream->readLong();
- m_aRowHeight <<= (sal_Int32)nValue;
+ m_aRowHeight <<= nValue;
}
FontDescriptor aFont( getFont() );
if ( nAnyMask & FONTATTRIBS )
@@ -970,7 +970,7 @@ void OGridControlModel::read(const Reference<XObjectInputStream>& _rxInStream)
if (nAnyMask & TEXTCOLOR)
{
sal_Int32 nValue = _rxInStream->readLong();
- setTextColor( (sal_Int32)nValue );
+ setTextColor( nValue );
}
// new since version 6
if (nVersion > 5)
@@ -989,7 +989,7 @@ void OGridControlModel::read(const Reference<XObjectInputStream>& _rxInStream)
if (nAnyMask & BACKGROUNDCOLOR)
{
sal_Int32 nValue = _rxInStream->readLong();
- m_aBackgroundColor <<= (sal_Int32)nValue;
+ m_aBackgroundColor <<= nValue;
}
}
diff --git a/forms/source/runtime/formoperations.cxx b/forms/source/runtime/formoperations.cxx
index a0c48f5fbe7a..4365661b9c60 100644
--- a/forms/source/runtime/formoperations.cxx
+++ b/forms/source/runtime/formoperations.cxx
@@ -339,13 +339,13 @@ namespace frm
{
if ( bIsNew )
nPosition = ++nCount;
- aState.State <<= (sal_Int32)nPosition;
+ aState.State <<= nPosition;
aState.Enabled = true;
}
}
else
{
- aState.State <<= (sal_Int32)nPosition;
+ aState.State <<= nPosition;
aState.Enabled = true;
}
}
@@ -835,7 +835,7 @@ namespace frm
sal_Int32 nCount = impl_getRowCount_throw();
bool bFinalCount = impl_isRowCountFinal_throw();
- if ( bFinalCount && ( (sal_Int32)nPosition > nCount ) )
+ if ( bFinalCount && ( nPosition > nCount ) )
nPosition = nCount;
m_xCursor->absolute( nPosition );
diff --git a/fpicker/source/office/OfficeControlAccess.cxx b/fpicker/source/office/OfficeControlAccess.cxx
index 74ba41a2b5e4..fbecfc328921 100644
--- a/fpicker/source/office/OfficeControlAccess.cxx
+++ b/fpicker/source/office/OfficeControlAccess.cxx
@@ -739,7 +739,7 @@ namespace svt
sal_Int32 nSelected = static_cast< ListBox* >( _pControl )->GetSelectEntryPos();
if ( LISTBOX_ENTRY_NOTFOUND != nSelected )
- aReturn <<= (sal_Int32)static_cast< ListBox* >( _pControl )->GetSelectEntryPos();
+ aReturn <<= static_cast< ListBox* >( _pControl )->GetSelectEntryPos();
else
aReturn <<= (sal_Int32)-1;
}
diff --git a/framework/source/accelerators/keymapping.cxx b/framework/source/accelerators/keymapping.cxx
index efbe78360d71..22bee0d2ce88 100644
--- a/framework/source/accelerators/keymapping.cxx
+++ b/framework/source/accelerators/keymapping.cxx
@@ -178,7 +178,7 @@ sal_uInt16 KeyMapping::mapIdentifierToCode(const OUString& sIdentifier)
css::uno::Reference< css::uno::XInterface >(),
0);
- return (sal_uInt16)nCode;
+ return nCode;
}
OUString KeyMapping::mapCodeToIdentifier(sal_uInt16 nCode)
diff --git a/framework/source/fwe/helper/titlehelper.cxx b/framework/source/fwe/helper/titlehelper.cxx
index 818a4595a4d4..ddce708ab7fe 100644
--- a/framework/source/fwe/helper/titlehelper.cxx
+++ b/framework/source/fwe/helper/titlehelper.cxx
@@ -354,7 +354,7 @@ void TitleHelper::impl_updateTitleForModel (const css::uno::Reference< css::fram
OUStringBuffer sNewTitle(256);
sNewTitle.append (xNumbers->getUntitledPrefix ());
if (nLeasedNumber != css::frame::UntitledNumbersConst::INVALID_NUMBER)
- sNewTitle.append ((::sal_Int32)nLeasedNumber);
+ sNewTitle.append(nLeasedNumber);
else
sNewTitle.append("?");
@@ -416,8 +416,8 @@ void TitleHelper::impl_updateTitleForController (const css::uno::Reference< css:
sTitle.append (xModelTitle->getTitle ());
if ( nLeasedNumber > 1 )
{
- sTitle.append (" : ");
- sTitle.append ((::sal_Int32)nLeasedNumber);
+ sTitle.append(" : ");
+ sTitle.append(nLeasedNumber);
}
if (xModel.is ())
{
@@ -435,7 +435,7 @@ void TitleHelper::impl_updateTitleForController (const css::uno::Reference< css:
sTitle.append (xNumbers->getUntitledPrefix ());
if ( nLeasedNumber > 1 )
{
- sTitle.append ((::sal_Int32)nLeasedNumber );
+ sTitle.append(nLeasedNumber );
}
}
diff --git a/framework/source/fwi/classes/converter.cxx b/framework/source/fwi/classes/converter.cxx
index 56070bcbcefd..b25f35e797c6 100644
--- a/framework/source/fwi/classes/converter.cxx
+++ b/framework/source/fwi/classes/converter.cxx
@@ -72,37 +72,37 @@ OUString Converter::convert_DateTime2ISO8601( const DateTime& aSource )
sBuffer.append("00");
else if (nYear<1000)
sBuffer.append("0");
- sBuffer.append( (sal_Int32)nYear );
+ sBuffer.append( nYear );
sBuffer.append("-");
// write month formatted as "MM"
if (nMonth<10)
sBuffer.append("0");
- sBuffer.append( (sal_Int32)nMonth );
+ sBuffer.append( nMonth );
sBuffer.append("-");
// write day formatted as "DD"
if (nDay<10)
sBuffer.append("0");
- sBuffer.append( (sal_Int32)nDay );
+ sBuffer.append( nDay );
sBuffer.append("T");
// write hours formatted as "hh"
if (nHour<10)
sBuffer.append("0");
- sBuffer.append( (sal_Int32)nHour );
+ sBuffer.append( nHour );
sBuffer.append(":");
// write min formatted as "mm"
if (nMin<10)
sBuffer.append("0");
- sBuffer.append( (sal_Int32)nMin );
+ sBuffer.append( nMin );
sBuffer.append(":");
// write sec formatted as "ss"
if (nSec<10)
sBuffer.append("0");
- sBuffer.append( (sal_Int32)nSec );
+ sBuffer.append( nSec );
sBuffer.append("Z");
diff --git a/io/source/acceptor/acc_socket.cxx b/io/source/acceptor/acc_socket.cxx
index 0759b3eff402..8a9907bbc67e 100644
--- a/io/source/acceptor/acc_socket.cxx
+++ b/io/source/acceptor/acc_socket.cxx
@@ -162,12 +162,12 @@ namespace io_acceptor {
{
OUStringBuffer buf( 256 );
buf.append( ",peerPort=" );
- buf.append( (sal_Int32) m_socket.getPeerPort() );
+ buf.append( m_socket.getPeerPort() );
buf.append( ",peerHost=" );
buf.append( m_socket.getPeerHost( ) );
buf.append( ",localPort=" );
- buf.append( (sal_Int32) m_socket.getLocalPort() );
+ buf.append( m_socket.getLocalPort() );
buf.append( ",localHost=" );
buf.append( m_socket.getLocalHost() );
diff --git a/io/source/connector/ctr_socket.cxx b/io/source/connector/ctr_socket.cxx
index e29111266ef4..35f4e80511a7 100644
--- a/io/source/connector/ctr_socket.cxx
+++ b/io/source/connector/ctr_socket.cxx
@@ -104,12 +104,12 @@ namespace stoc_connector {
OUStringBuffer buf( 256 );
buf.append( ",peerPort=" );
- buf.append( (sal_Int32) nPort );
+ buf.append( nPort );
buf.append( ",peerHost=" );
buf.append( m_socket.getPeerHost() );
buf.append( ",localPort=" );
- buf.append( (sal_Int32) nPort );
+ buf.append( nPort );
buf.append( ",localHost=" );
buf.append( m_socket.getLocalHost( ) );
diff --git a/linguistic/source/dicimp.cxx b/linguistic/source/dicimp.cxx
index ad76249b8280..4eac9e2a958f 100644
--- a/linguistic/source/dicimp.cxx
+++ b/linguistic/source/dicimp.cxx
@@ -565,7 +565,7 @@ int DictionaryNeo::cmpDicEntry(const OUString& rWord1,
nIdx2++;
}
- nRes = ((sal_Int32) nLen1 - nNumIgnChar1) - ((sal_Int32) nLen2 - nNumIgnChar2);
+ nRes = (nLen1 - nNumIgnChar1) - (nLen2 - nNumIgnChar2);
}
return nRes;
diff --git a/lotuswordpro/source/filter/xfilter/xfbase64.cxx b/lotuswordpro/source/filter/xfilter/xfbase64.cxx
index ca400eda93e4..5fdd0a2c4346 100644
--- a/lotuswordpro/source/filter/xfilter/xfbase64.cxx
+++ b/lotuswordpro/source/filter/xfilter/xfbase64.cxx
@@ -73,9 +73,9 @@ const sal_Char aBase64EncodeTable[] =
*/
inline void Encode_(sal_uInt8 *src, sal_Char* dest)
{
- sal_Int32 nBinaer = (((sal_uInt8)src[ 0]) << 16) +
- (((sal_uInt8)src[1]) << 8) +
- ((sal_uInt8)src[2]);
+ sal_Int32 nBinaer = (src[ 0] << 16) +
+ (src[1] << 8) +
+ (src[2]);
sal_uInt8 nIndex = ((nBinaer & 0xFC0000) >> 18);
dest[0] = aBase64EncodeTable [nIndex];
diff --git a/oox/source/drawingml/customshapegeometry.cxx b/oox/source/drawingml/customshapegeometry.cxx
index 37a6281f160d..471bca3f0327 100644
--- a/oox/source/drawingml/customshapegeometry.cxx
+++ b/oox/source/drawingml/customshapegeometry.cxx
@@ -388,7 +388,7 @@ static EnhancedCustomShapeParameter GetAdjCoordinate( CustomShapeProperties& rCu
}
if ( ( n >= '0' ) && ( n <= '9' ) )
{ // seems to be a ST_Coordinate
- aRet.Value <<= (sal_Int32)(rValue.toInt32() );
+ aRet.Value <<= rValue.toInt32();
aRet.Type = EnhancedCustomShapeParameterType::NORMAL;
}
else
diff --git a/oox/source/ppt/commontimenodecontext.cxx b/oox/source/ppt/commontimenodecontext.cxx
index c6920899b45e..ca0c1c01da82 100644
--- a/oox/source/ppt/commontimenodecontext.cxx
+++ b/oox/source/ppt/commontimenodecontext.cxx
@@ -430,7 +430,7 @@ OUString getConvertedSubType( sal_Int16 nPresetClass, sal_Int32 nPresetId, sal_I
nEnum = AnimationFill::DEFAULT;
break;
}
- aProps[ NP_FILL ] <<= (sal_Int16)nEnum;
+ aProps[ NP_FILL ] <<= nEnum;
}
}
if( attribs.hasAttribute( XML_grpId ) )
@@ -578,7 +578,7 @@ OUString getConvertedSubType( sal_Int16 nPresetClass, sal_Int32 nPresetId, sal_I
nEnum = AnimationRestart::DEFAULT;
break;
}
- aProps[ NP_RESTART ] <<= (sal_Int16)nEnum;
+ aProps[ NP_RESTART ] <<= nEnum;
}
// ST_Percentage TODO
xAttribs->getOptionalValue( XML_spd /*"10000" */ );
diff --git a/oox/source/ppt/pptshape.cxx b/oox/source/ppt/pptshape.cxx
index bfcf8a21d832..3d109e310682 100644
--- a/oox/source/ppt/pptshape.cxx
+++ b/oox/source/ppt/pptshape.cxx
@@ -332,7 +332,7 @@ void PPTShape::addShape(
setMasterTextListStyle( aMasterTextListStyle );
Reference< XShape > xShape( createAndInsert( rFilterBase, sServiceName, pTheme, rxShapes, bClearText, mpPlaceholder.get() != nullptr, aTransformation, getFillProperties() ) );
- if (!rSlidePersist.isMasterPage() && rSlidePersist.getPage().is() && ((sal_Int32)mnSubType == XML_title))
+ if (!rSlidePersist.isMasterPage() && rSlidePersist.getPage().is() && mnSubType == XML_title)
{
try
{
diff --git a/oox/source/ppt/timenodelistcontext.cxx b/oox/source/ppt/timenodelistcontext.cxx
index ef62a85e44f2..e97a8f148b84 100644
--- a/oox/source/ppt/timenodelistcontext.cxx
+++ b/oox/source/ppt/timenodelistcontext.cxx
@@ -291,7 +291,7 @@ namespace oox { namespace ppt {
}
break;
}
- mpNode->getNodeProperties()[ NP_COMMAND ] <<= (sal_Int16)nCommand;
+ mpNode->getNodeProperties()[ NP_COMMAND ] <<= nCommand;
if( nCommand == EffectCommands::CUSTOM )
{
SAL_WARN("oox.ppt", "OOX: CmdTimeNodeContext::endFastElement(), unknown command!");
diff --git a/pyuno/source/module/pyuno_adapter.cxx b/pyuno/source/module/pyuno_adapter.cxx
index 3a3b5728dc17..52f7577c550b 100644
--- a/pyuno/source/module/pyuno_adapter.cxx
+++ b/pyuno/source/module/pyuno_adapter.cxx
@@ -280,7 +280,7 @@ Any Adapter::invoke( const OUString &aFunctionName,
buf.append( "pyuno bridge: expected for method " );
buf.append( aFunctionName );
buf.append( " one return value and " );
- buf.append( (sal_Int32) aOutParamIndex.getLength() );
+ buf.append( aOutParamIndex.getLength() );
buf.append( " out parameters, got a sequence of " );
buf.append( seq.getLength() );
buf.append( " elements as return value." );
diff --git a/reportdesign/source/filter/xml/xmlControlProperty.cxx b/reportdesign/source/filter/xml/xmlControlProperty.cxx
index 05797c5dad45..ad1ba750342d 100644
--- a/reportdesign/source/filter/xml/xmlControlProperty.cxx
+++ b/reportdesign/source/filter/xml/xmlControlProperty.cxx
@@ -220,7 +220,7 @@ Any OXMLControlProperty::convertString(const css::uno::Type& _rExpectedType, con
if (TypeClass_SHORT == _rExpectedType.getTypeClass())
aReturn <<= (sal_Int16)nValue;
else
- aReturn <<= (sal_Int32)nValue;
+ aReturn <<= nValue;
break;
}
case TypeClass_HYPER:
diff --git a/rsc/source/res/rscconst.cxx b/rsc/source/res/rscconst.cxx
index 845cb2322a26..81c9010572df 100644
--- a/rsc/source/res/rscconst.cxx
+++ b/rsc/source/res/rscconst.cxx
@@ -123,7 +123,7 @@ ERRTYPE RscEnum::SetNumber( const RSCINST & rInst, sal_Int32 lValue )
for( i = 0; i < nEntries; i++ )
{
- if( (sal_Int32)pVarArray[ i ].lValue == lValue )
+ if( pVarArray[ i ].lValue == lValue )
return SetConst( rInst, pVarArray[ i ].nId, lValue );
}
@@ -183,7 +183,7 @@ void RscEnum::WriteSrc( const RSCINST & rInst, FILE * fOutput,
ERRTYPE RscEnum::WriteRc( const RSCINST & rInst, RscWriteRc & aMem,
RscTypCont *, sal_uInt32 )
{
- aMem.Put( (sal_Int32)pVarArray[ reinterpret_cast<RscEnumInst *>(rInst.pData)->nValue ].lValue );
+ aMem.Put( pVarArray[ reinterpret_cast<RscEnumInst *>(rInst.pData)->nValue ].lValue );
return ERR_OK;
}
diff --git a/rsc/source/res/rsccont.cxx b/rsc/source/res/rsccont.cxx
index fbc36d4d9dc9..033ec345f380 100644
--- a/rsc/source/res/rsccont.cxx
+++ b/rsc/source/res/rsccont.cxx
@@ -534,8 +534,8 @@ bool RscBaseCont::IsConsistent( const RSCINST & rInst )
{
if( !bNoId )
{
- if( (sal_Int32)pClassData->pEntries[ i ].aName.GetNumber() > 0x7FFF ||
- (sal_Int32)pClassData->pEntries[ i ].aName.GetNumber() < 1 )
+ if( pClassData->pEntries[ i ].aName.GetNumber() > 0x7FFF ||
+ pClassData->pEntries[ i ].aName.GetNumber() < 1 )
{
bRet = false;
}
diff --git a/rsc/source/res/rscflag.cxx b/rsc/source/res/rscflag.cxx
index 6321317baf1f..10661816092f 100644
--- a/rsc/source/res/rscflag.cxx
+++ b/rsc/source/res/rscflag.cxx
@@ -288,7 +288,7 @@ ERRTYPE RscFlag::WriteRc( const RSCINST & rInst, RscWriteRc & aMem,
Flag = 1;
}
- aMem.Put( (sal_Int32)lVal );
+ aMem.Put( lVal );
return ERR_OK;
}
diff --git a/rsc/source/res/rscrange.cxx b/rsc/source/res/rscrange.cxx
index c252c625b823..a5ef683b7ee0 100644
--- a/rsc/source/res/rscrange.cxx
+++ b/rsc/source/res/rscrange.cxx
@@ -236,7 +236,7 @@ ERRTYPE RscLongRange::WriteRc( const RSCINST & rInst, RscWriteRc & aMem,
sal_Int32 lVal;
GetNumber( rInst, &lVal );
- aMem.Put( (sal_Int32)lVal );
+ aMem.Put( lVal );
return ERR_OK;
}
@@ -376,7 +376,7 @@ ERRTYPE RscIdRange::WriteRc( const RSCINST & rInst, RscWriteRc & aMem,
{
sal_Int32 lVal = reinterpret_cast<RscId*>(rInst.pData)->GetNumber();
- aMem.Put( (sal_Int32)lVal );
+ aMem.Put( lVal );
return ERR_OK;
}
diff --git a/rsc/source/tools/rsctree.cxx b/rsc/source/tools/rsctree.cxx
index 410b7bb58b46..6add08277267 100644
--- a/rsc/source/tools/rsctree.cxx
+++ b/rsc/source/tools/rsctree.cxx
@@ -331,9 +331,9 @@ IdNode * IdNode::Search( sal_uInt32 nTypeName ) const
COMPARE IdNode::Compare( const NameNode * pSearch ) const
{
- if( GetId() < (sal_uInt32)(static_cast<const IdNode *>(pSearch)->GetId()) )
+ if( GetId() < static_cast<const IdNode *>(pSearch)->GetId() )
return LESS;
- else if( GetId() > (sal_uInt32)(static_cast<const IdNode *>(pSearch)->GetId()) )
+ else if( GetId() > static_cast<const IdNode *>(pSearch)->GetId() )
return GREATER;
else
return EQUAL;
diff --git a/sc/source/core/data/attarray.cxx b/sc/source/core/data/attarray.cxx
index d6ea28a409b9..a55f8dcfd260 100644
--- a/sc/source/core/data/attarray.cxx
+++ b/sc/source/core/data/attarray.cxx
@@ -1264,7 +1264,7 @@ void ScAttrArray::ApplyBlockFrame( const SvxBoxItem* pLineOuter, const SvxBoxInf
SCROW nTmpEnd;
for (SCSIZE i=nStartIndex; i<=nEndIndex;)
{
- nTmpEnd = std::min( (SCROW)(nEndRow-1), (SCROW)(pData[i].nRow) );
+ nTmpEnd = std::min( (SCROW)(nEndRow-1), pData[i].nRow );
bool bChanged = ApplyFrame( pLineOuter, pLineInner, nTmpStart, nTmpEnd,
bLeft, nDistRight, false, nEndRow-nTmpEnd );
nTmpStart = nTmpEnd+1;
@@ -1587,7 +1587,7 @@ void ScAttrArray::SetPatternAreaSafe( SCROW nStartRow, SCROW nEndRow,
{
if (nThisRow < nStartRow) nThisRow = nStartRow;
nRow = pData[nIndex].nRow;
- SCROW nAttrRow = std::min( (SCROW)nRow, (SCROW)nEndRow );
+ SCROW nAttrRow = std::min( nRow, nEndRow );
pItem = static_cast<const ScMergeFlagAttr*>( &pOldPattern->GetItem( ATTR_MERGE_FLAG ) );
if (pItem->IsOverlapped() || pItem->HasAutoFilter())
@@ -1644,7 +1644,7 @@ bool ScAttrArray::ApplyFlags( SCROW nStartRow, SCROW nEndRow, ScMF nFlags )
if ( (nOldValue | nFlags) != nOldValue )
{
nRow = pData[nIndex].nRow;
- SCROW nAttrRow = std::min( (SCROW)nRow, (SCROW)nEndRow );
+ SCROW nAttrRow = std::min( nRow, nEndRow );
ScPatternAttr aNewPattern(*pOldPattern);
aNewPattern.GetItemSet().Put( ScMergeFlagAttr( nOldValue | nFlags ) );
SetPatternArea( nThisRow, nAttrRow, &aNewPattern, true );
@@ -1681,7 +1681,7 @@ bool ScAttrArray::RemoveFlags( SCROW nStartRow, SCROW nEndRow, ScMF nFlags )
if ( (nOldValue & ~nFlags) != nOldValue )
{
nRow = pData[nIndex].nRow;
- SCROW nAttrRow = std::min( (SCROW)nRow, (SCROW)nEndRow );
+ SCROW nAttrRow = std::min( nRow, nEndRow );
ScPatternAttr aNewPattern(*pOldPattern);
aNewPattern.GetItemSet().Put( ScMergeFlagAttr( nOldValue & ~nFlags ) );
SetPatternArea( nThisRow, nAttrRow, &aNewPattern, true );
@@ -1716,7 +1716,7 @@ void ScAttrArray::ClearItems( SCROW nStartRow, SCROW nEndRow, const sal_uInt16*
aNewPattern.ClearItems( pWhich );
nRow = pData[nIndex].nRow;
- SCROW nAttrRow = std::min( (SCROW)nRow, (SCROW)nEndRow );
+ SCROW nAttrRow = std::min( nRow, nEndRow );
SetPatternArea( nThisRow, nAttrRow, &aNewPattern, true );
Search( nThisRow, nIndex ); // data changed
}
@@ -2378,7 +2378,7 @@ void ScAttrArray::DeleteHardAttr(SCROW nStartRow, SCROW nEndRow)
if ( pOldPattern->GetItemSet().Count() ) // hard attributes ?
{
nRow = pData[nIndex].nRow;
- SCROW nAttrRow = std::min( (SCROW)nRow, (SCROW)nEndRow );
+ SCROW nAttrRow = std::min( nRow, nEndRow );
ScPatternAttr aNewPattern(*pOldPattern);
SfxItemSet& rSet = aNewPattern.GetItemSet();
@@ -2411,10 +2411,10 @@ void ScAttrArray::MoveTo(SCROW nStartRow, SCROW nEndRow, ScAttrArray& rAttrArray
if ((pData[i].nRow >= nStartRow) && (i == 0 || pData[i-1].nRow < nEndRow))
{
// copy (bPutToPool=TRUE)
- rAttrArray.SetPatternArea( nStart, std::min( (SCROW)pData[i].nRow, (SCROW)nEndRow ),
+ rAttrArray.SetPatternArea( nStart, std::min( pData[i].nRow, nEndRow ),
pData[i].pPattern, true );
}
- nStart = std::max( (SCROW)nStart, (SCROW)(pData[i].nRow + 1) );
+ nStart = std::max( nStart, pData[i].nRow + 1 );
}
DeleteArea(nStartRow, nEndRow);
}
diff --git a/sc/source/core/data/column3.cxx b/sc/source/core/data/column3.cxx
index a143f88bd0b4..e378dd0384b8 100644
--- a/sc/source/core/data/column3.cxx
+++ b/sc/source/core/data/column3.cxx
@@ -1780,7 +1780,7 @@ bool ScColumn::ParseString(
if ( bOverwrite )
{
ApplyAttr( nRow, SfxUInt32Item( ATTR_VALUE_FORMAT,
- (sal_uInt32) nIndex) );
+ nIndex) );
bNumFmtSet = true;
}
}
diff --git a/sc/source/core/data/poolhelp.cxx b/sc/source/core/data/poolhelp.cxx
index 32b0bd2cb462..0ad8c56acf19 100644
--- a/sc/source/core/data/poolhelp.cxx
+++ b/sc/source/core/data/poolhelp.cxx
@@ -84,7 +84,7 @@ void ScPoolHelper::SetFormTableOpt(const ScDocOptions& rOpt)
sal_Int16 y;
aOpt.GetDate( d,m,y );
pFormTable->ChangeNullDate( d,m,y );
- pFormTable->ChangeStandardPrec( (sal_uInt16)aOpt.GetStdPrecision() );
+ pFormTable->ChangeStandardPrec( aOpt.GetStdPrecision() );
pFormTable->SetYear2000( aOpt.GetYear2000() );
}
}
diff --git a/sc/source/core/data/table2.cxx b/sc/source/core/data/table2.cxx
index 7d7ed84dad15..25f81d0d4cac 100644
--- a/sc/source/core/data/table2.cxx
+++ b/sc/source/core/data/table2.cxx
@@ -3026,7 +3026,7 @@ sal_uInt16 ScTable::GetRowHeight( SCROW nRow, SCROW* pStartRow, SCROW* pEndRow,
*pStartRow = nRow;
if (pEndRow)
*pEndRow = nRow;
- return (sal_uInt16) ScGlobal::nStdRowHeight;
+ return ScGlobal::nStdRowHeight;
}
}
@@ -3102,7 +3102,7 @@ sal_uInt16 ScTable::GetOriginalHeight( SCROW nRow ) const // non-0 even if
if (ValidRow(nRow) && mpRowHeights)
return mpRowHeights->getValue(nRow);
else
- return (sal_uInt16) ScGlobal::nStdRowHeight;
+ return ScGlobal::nStdRowHeight;
}
// Column/Row -Flags
diff --git a/sc/source/core/tool/appoptio.cxx b/sc/source/core/tool/appoptio.cxx
index 8b06ea8bbf63..1f726f5c1828 100644
--- a/sc/source/core/tool/appoptio.cxx
+++ b/sc/source/core/tool/appoptio.cxx
@@ -672,10 +672,10 @@ IMPL_LINK_NOARG(ScAppCfg, MiscCommitHdl, ScLinkConfigItem&, void)
switch(nProp)
{
case SCMISCOPT_DEFOBJWIDTH:
- pValues[nProp] <<= (sal_Int32) GetDefaultObjectSizeWidth();
+ pValues[nProp] <<= GetDefaultObjectSizeWidth();
break;
case SCMISCOPT_DEFOBJHEIGHT:
- pValues[nProp] <<= (sal_Int32) GetDefaultObjectSizeHeight();
+ pValues[nProp] <<= GetDefaultObjectSizeHeight();
break;
case SCMISCOPT_SHOWSHAREDDOCWARN:
pValues[nProp] <<= GetShowSharedDocumentWarning();
diff --git a/sc/source/core/tool/interpr1.cxx b/sc/source/core/tool/interpr1.cxx
index fc5e8384c9b6..f8d682a9c1c5 100644
--- a/sc/source/core/tool/interpr1.cxx
+++ b/sc/source/core/tool/interpr1.cxx
@@ -8077,7 +8077,7 @@ bool SAL_CALL lcl_getScriptClass(sal_uInt32 currentChar)
return true;
sal_uInt16 i;
static bool bRet = false;
- UBlockCode block = ublock_getCode((sal_uInt32)currentChar);
+ UBlockCode block = ublock_getCode(currentChar);
for ( i = 0; i < scriptListCount; i++) {
if (block <= scriptList[i].to) break;
}
diff --git a/sc/source/filter/html/htmlexp.cxx b/sc/source/filter/html/htmlexp.cxx
index 500efa900c36..6372fee39669 100644
--- a/sc/source/filter/html/htmlexp.cxx
+++ b/sc/source/filter/html/htmlexp.cxx
@@ -362,7 +362,7 @@ void ScHTMLExport::WriteHeader()
{ // Fontlist, VCL: Semicolon as separator
// CSS1: Comma as separator and every single font name quoted
const OUString& rList = aHTMLStyle.aFontFamilyName;
- for ( sal_Int32 j = 0, nPos = 0; j < (sal_Int32) nFonts; j++ )
+ for ( sal_Int32 j = 0, nPos = 0; j < nFonts; j++ )
{
rStrm.WriteChar( '\"' );
OUT_STR( rList.getToken( 0, ';', nPos ) );
@@ -1116,7 +1116,7 @@ void ScHTMLExport::WriteCell( SCCOL nCol, SCROW nRow, SCTAB nTab )
else
{ // Font list, VCL: Semicolon as separator, HTML: Comma
const OUString& rList = rFontItem.GetFamilyName();
- for ( sal_Int32 j = 0, nPos = 0; j < (sal_Int32)nFonts; j++ )
+ for ( sal_Int32 j = 0, nPos = 0; j < nFonts; j++ )
{
OString aTmpStr = HTMLOutFuncs::ConvertStringToHTML(
rList.getToken( 0, ';', nPos ), eDestEnc,
diff --git a/sc/source/filter/starcalc/scflt.cxx b/sc/source/filter/starcalc/scflt.cxx
index 44529b1e58b7..0f7f337bedbf 100644
--- a/sc/source/filter/starcalc/scflt.cxx
+++ b/sc/source/filter/starcalc/scflt.cxx
@@ -1353,7 +1353,7 @@ void Sc10Import::LoadDataBaseCollection()
{
Sc10DataBaseData* pOldData = pDataBaseCollection->At(i);
ScDBData* pNewData = new ScDBData( SC10TOSTRING( pOldData->DataBaseRec.Name ),
- ( SCTAB ) pOldData->DataBaseRec.Tab,
+ pOldData->DataBaseRec.Tab,
( SCCOL ) pOldData->DataBaseRec.Block.x1,
( SCROW ) pOldData->DataBaseRec.Block.y1,
( SCCOL ) pOldData->DataBaseRec.Block.x2,
diff --git a/sc/source/filter/xcl97/xcl97rec.cxx b/sc/source/filter/xcl97/xcl97rec.cxx
index 6a7ca5c2cc4a..db77e64f573f 100644
--- a/sc/source/filter/xcl97/xcl97rec.cxx
+++ b/sc/source/filter/xcl97/xcl97rec.cxx
@@ -1417,7 +1417,7 @@ void ExcEScenario::SaveCont( XclExpStream& rStrm )
{
sal_uInt16 count = aCells.size();
- rStrm << (sal_uInt16) count // number of cells
+ rStrm << count // number of cells
<< sal_uInt8(bProtected) // fProtection
<< (sal_uInt8) 0 // fHidden
<< (sal_uInt8) sName.Len() // length of scen name
diff --git a/sc/source/ui/Accessibility/AccessibleCellBase.cxx b/sc/source/ui/Accessibility/AccessibleCellBase.cxx
index acece6d3de55..ef31889dbb29 100644
--- a/sc/source/ui/Accessibility/AccessibleCellBase.cxx
+++ b/sc/source/ui/Accessibility/AccessibleCellBase.cxx
@@ -411,7 +411,7 @@ OUString SAL_CALL ScAccessibleCellBase::getShadowAttrs()
}
//else return all the shadow properties
sShadowAttrs += "Location=";
- sShadowAttrs += OUString::number( (sal_Int32)nLocationVal );
+ sShadowAttrs += OUString::number( nLocationVal );
sShadowAttrs += sInnerSplit;
sShadowAttrs += "ShadowWidth=";
sShadowAttrs += OUString::number( (sal_Int32)aShadowFmt.ShadowWidth ) ;
diff --git a/sc/source/ui/dbgui/scuiimoptdlg.cxx b/sc/source/ui/dbgui/scuiimoptdlg.cxx
index 33db5aa95bd0..38ec2fbdf6c8 100644
--- a/sc/source/ui/dbgui/scuiimoptdlg.cxx
+++ b/sc/source/ui/dbgui/scuiimoptdlg.cxx
@@ -184,7 +184,7 @@ ScImportOptionsDlg::ScImportOptionsDlg(
aStr = pFieldSepTab->GetDelimiter( nCode );
if ( aStr.isEmpty() )
- m_pEdFieldSep->SetText( OUString((sal_Unicode)nCode) );
+ m_pEdFieldSep->SetText( OUString(nCode) );
else
m_pEdFieldSep->SetText( aStr );
@@ -192,7 +192,7 @@ ScImportOptionsDlg::ScImportOptionsDlg(
aStr = pTextSepTab->GetDelimiter( nCode );
if ( aStr.isEmpty() )
- m_pEdTextSep->SetText( OUString((sal_Unicode)nCode) );
+ m_pEdTextSep->SetText( OUString(nCode) );
else
m_pEdTextSep->SetText( aStr );
}
diff --git a/sc/source/ui/dbgui/validate.cxx b/sc/source/ui/dbgui/validate.cxx
index e7ac7891b1bb..b2f690c73a70 100644
--- a/sc/source/ui/dbgui/validate.cxx
+++ b/sc/source/ui/dbgui/validate.cxx
@@ -272,7 +272,7 @@ void lclGetFormulaFromStringList( OUString& rFmlaStr, const OUString& rStringLis
{
rFmlaStr.clear();
sal_Int32 nTokenCnt = comphelper::string::getTokenCount(rStringList, '\n');
- for( sal_Int32 nToken = 0, nStringIx = 0; nToken < (sal_Int32) nTokenCnt; ++nToken )
+ for( sal_Int32 nToken = 0, nStringIx = 0; nToken < nTokenCnt; ++nToken )
{
OUString aToken( rStringList.getToken( 0, '\n', nStringIx ) );
ScGlobal::AddQuotes( aToken, '"' );
diff --git a/sc/source/ui/docshell/docsh8.cxx b/sc/source/ui/docshell/docsh8.cxx
index 6e7d2b63d47c..9f7942a86081 100644
--- a/sc/source/ui/docshell/docsh8.cxx
+++ b/sc/source/ui/docshell/docsh8.cxx
@@ -124,7 +124,7 @@ namespace
::std::vector< rtl_TextEncoding > aEncodings;
svxform::charset_helper::getSupportedTextEncodings( aEncodings );
- ::std::vector< rtl_TextEncoding >::iterator aIter = ::std::find(aEncodings.begin(),aEncodings.end(),(rtl_TextEncoding) eCharSet);
+ ::std::vector< rtl_TextEncoding >::iterator aIter = ::std::find(aEncodings.begin(),aEncodings.end(), eCharSet);
if ( aIter == aEncodings.end() )
{
OSL_FAIL( "DBaseImport: dbtools::OCharsetMap doesn't know text encoding" );
diff --git a/sc/source/ui/drawfunc/drtxtob.cxx b/sc/source/ui/drawfunc/drtxtob.cxx
index 3887ac22669b..ce6f08f1329b 100644
--- a/sc/source/ui/drawfunc/drtxtob.cxx
+++ b/sc/source/ui/drawfunc/drtxtob.cxx
@@ -1081,8 +1081,7 @@ void ScDrawTextObjectBar::GetAttrState( SfxItemSet& rDestSet )
// Zeilenabstand
- sal_uInt16 nLineSpace = (sal_uInt16)
- static_cast<const SvxLineSpacingItem&>(aAttrSet.
+ sal_uInt16 nLineSpace = static_cast<const SvxLineSpacingItem&>(aAttrSet.
Get( EE_PARA_SBL )).GetPropLineSpace();
switch( nLineSpace )
{
diff --git a/sc/source/ui/optdlg/tpview.cxx b/sc/source/ui/optdlg/tpview.cxx
index 84b6535f61e0..986f9d2dd06d 100644
--- a/sc/source/ui/optdlg/tpview.cxx
+++ b/sc/source/ui/optdlg/tpview.cxx
@@ -427,8 +427,7 @@ bool ScTpLayoutOptions::FillItemSet( SfxItemSet* rCoreSet )
if ( m_pUnitLB->IsValueChangedFromSaved() )
{
sal_uInt16 nFieldUnit = (sal_uInt16)reinterpret_cast<sal_IntPtr>(m_pUnitLB->GetEntryData( nMPos ));
- rCoreSet->Put( SfxUInt16Item( SID_ATTR_METRIC,
- (sal_uInt16)nFieldUnit ) );
+ rCoreSet->Put( SfxUInt16Item( SID_ATTR_METRIC, nFieldUnit ) );
bRet = true;
}
diff --git a/sc/source/ui/unoobj/appluno.cxx b/sc/source/ui/unoobj/appluno.cxx
index fcf724a9f486..4904d755e110 100644
--- a/sc/source/ui/unoobj/appluno.cxx
+++ b/sc/source/ui/unoobj/appluno.cxx
@@ -418,7 +418,7 @@ uno::Any SAL_CALL ScSpreadsheetSettings::getPropertyValue( const OUString& aProp
// added to avoid warnings
}
}
- aRet <<= (sal_Int16) nZoomVal;
+ aRet <<= nZoomVal;
}
else if (aPropertyName == SC_UNONAME_ULISTS )
{
diff --git a/sc/source/ui/view/select.cxx b/sc/source/ui/view/select.cxx
index b4c99e6831ca..014bd6371450 100644
--- a/sc/source/ui/view/select.cxx
+++ b/sc/source/ui/view/select.cxx
@@ -679,7 +679,7 @@ bool ScViewFunctionSet::SetCursorAtCell( SCsCOL nPosX, SCsROW nPosY, bool bScrol
SCROW nOldY = pViewData->GetCurY();
pView->InitBlockMode( nOldX, nOldY, nTab, true );
- pView->MarkCursor( (SCCOL) nOldX, (SCROW) nOldY, nTab );
+ pView->MarkCursor( nOldX, nOldY, nTab );
if ( nOldX != nPosX || nOldY != nPosY )
{
diff --git a/sc/source/ui/view/tabview3.cxx b/sc/source/ui/view/tabview3.cxx
index 9b03379f4cc2..abbd807a1ade 100644
--- a/sc/source/ui/view/tabview3.cxx
+++ b/sc/source/ui/view/tabview3.cxx
@@ -169,7 +169,7 @@ void ScTabView::ClickCursor( SCCOL nPosX, SCROW nPosY, bool bControl )
{
DoneBlockMode( bControl );
aViewData.ResetOldCursor();
- SetCursor( (SCCOL) nPosX, (SCROW) nPosY );
+ SetCursor( nPosX, nPosY );
}
}
diff --git a/scaddins/source/analysis/analysishelper.cxx b/scaddins/source/analysis/analysishelper.cxx
index 886a83316d3c..e49ca081e954 100644
--- a/scaddins/source/analysis/analysishelper.cxx
+++ b/scaddins/source/analysis/analysishelper.cxx
@@ -234,7 +234,7 @@ void DaysToDate( sal_Int32 nDays, sal_uInt16& rDay, sal_uInt16& rMonth, sal_uInt
while ( bCalc );
rMonth = 1;
- while ( (sal_Int32)nTempDays > DaysInMonth( rMonth, rYear ) )
+ while ( nTempDays > DaysInMonth( rMonth, rYear ) )
{
nTempDays -= DaysInMonth( rMonth, rYear );
rMonth++;
diff --git a/scaddins/source/datefunc/datefunc.cxx b/scaddins/source/datefunc/datefunc.cxx
index 61db3584e6df..98205fb75f82 100644
--- a/scaddins/source/datefunc/datefunc.cxx
+++ b/scaddins/source/datefunc/datefunc.cxx
@@ -465,7 +465,7 @@ void DaysToDate( sal_Int32 nDays,
while ( bCalc );
rMonth = 1;
- while ( (sal_Int32)nTempDays > DaysInMonth( rMonth, rYear ) )
+ while ( nTempDays > DaysInMonth( rMonth, rYear ) )
{
nTempDays -= DaysInMonth( rMonth, rYear );
rMonth++;
diff --git a/sd/source/filter/eppt/pptx-epptooxml.cxx b/sd/source/filter/eppt/pptx-epptooxml.cxx
index 8b2fa727dbb9..c3d296878ab3 100644
--- a/sd/source/filter/eppt/pptx-epptooxml.cxx
+++ b/sd/source/filter/eppt/pptx-epptooxml.cxx
@@ -1803,7 +1803,7 @@ void PowerPointExport::ImplWritePPTXLayout( sal_Int32 nOffset, sal_uInt32 nMaste
FSHelperPtr pFS
= openFragmentStreamWithSerializer( OUStringBuffer()
.append( "ppt/slideLayouts/slideLayout" )
- .append( (sal_Int32) mnLayoutFileIdMax )
+ .append( mnLayoutFileIdMax )
.append( ".xml" )
.makeStringAndClear(),
"application/vnd.openxmlformats-officedocument.presentationml.slideLayout+xml" );
@@ -2178,7 +2178,7 @@ void PowerPointExport::WriteTheme( sal_Int32 nThemeNum )
{
FSHelperPtr pFS = openFragmentStreamWithSerializer( OUStringBuffer()
.append( "ppt/theme/theme" )
- .append( (sal_Int32) nThemeNum + 1 )
+ .append( nThemeNum + 1 )
.append( ".xml" )
.makeStringAndClear(),
"application/vnd.openxmlformats-officedocument.theme+xml" );
diff --git a/sd/source/filter/ppt/pptinanimations.cxx b/sd/source/filter/ppt/pptinanimations.cxx
index 22b21c66c063..7e67d544226e 100644
--- a/sd/source/filter/ppt/pptinanimations.cxx
+++ b/sd/source/filter/ppt/pptinanimations.cxx
@@ -2800,8 +2800,8 @@ void AnimationImporter::importTargetElementContainer( const Atom* pAtom, Any& rT
rTarget <<= aParaTarget;
rSubType = ShapeAnimationSubType::ONLY_TEXT;
- dump( " paragraph %d,", (sal_Int32)nPara);
- dump( " %d characters", (sal_Int32)end );
+ dump( " paragraph %d,", nPara);
+ dump( " %d characters", end );
}
}
}
diff --git a/sd/source/ui/app/optsitem.cxx b/sd/source/ui/app/optsitem.cxx
index b13b7ec456df..3643af570c78 100644
--- a/sd/source/ui/app/optsitem.cxx
+++ b/sd/source/ui/app/optsitem.cxx
@@ -954,8 +954,8 @@ bool SdOptionsZoom::WriteData( Any* pValues ) const
GetScale( x, y );
- pValues[ 0 ] <<= (sal_Int32) x;
- pValues[ 1 ] <<= (sal_Int32) y;
+ pValues[ 0 ] <<= x;
+ pValues[ 1 ] <<= y;
return true;
}
diff --git a/sd/source/ui/app/sdmod2.cxx b/sd/source/ui/app/sdmod2.cxx
index 88b261a8fe60..f6e25fc72c94 100644
--- a/sd/source/ui/app/sdmod2.cxx
+++ b/sd/source/ui/app/sdmod2.cxx
@@ -307,7 +307,7 @@ IMPL_LINK(SdModule, CalcFieldValueHdl, EditFieldInfo*, pInfo, void)
}
else if( pDoc )
{
- nPageCount = (sal_uInt16)pDoc->GetActiveSdPageCount();
+ nPageCount = pDoc->GetActiveSdPageCount();
}
}
diff --git a/sd/source/ui/dlg/present.cxx b/sd/source/ui/dlg/present.cxx
index 58ff4cafb6c8..c4788163f413 100644
--- a/sd/source/ui/dlg/present.cxx
+++ b/sd/source/ui/dlg/present.cxx
@@ -91,7 +91,7 @@ SdStartPresentationDlg::SdStartPresentationDlg( vcl::Window* pWindow,
if( pCustomShowList )
{
- sal_uInt16 nPosToSelect = (sal_uInt16) pCustomShowList->GetCurPos();
+ sal_uInt16 nPosToSelect = pCustomShowList->GetCurPos();
SdCustomShow* pCustomShow;
// fill Listbox with CustomShows
for( pCustomShow = pCustomShowList->First();
diff --git a/sd/source/ui/dlg/tpoption.cxx b/sd/source/ui/dlg/tpoption.cxx
index 2700f8ee94eb..a1e6019ee567 100644
--- a/sd/source/ui/dlg/tpoption.cxx
+++ b/sd/source/ui/dlg/tpoption.cxx
@@ -420,8 +420,7 @@ bool SdTpOptionsMisc::FillItemSet( SfxItemSet* rAttrs )
if ( m_pLbMetric->IsValueChangedFromSaved() )
{
sal_uInt16 nFieldUnit = (sal_uInt16)reinterpret_cast<sal_IntPtr>(m_pLbMetric->GetEntryData( nMPos ));
- rAttrs->Put( SfxUInt16Item( GetWhich( SID_ATTR_METRIC ),
- (sal_uInt16)nFieldUnit ) );
+ rAttrs->Put( SfxUInt16Item( GetWhich( SID_ATTR_METRIC ), nFieldUnit ) );
bModified = true;
}
diff --git a/sd/source/ui/docshell/docshel2.cxx b/sd/source/ui/docshell/docshel2.cxx
index f43bc1a71d2d..cecf385fd9c7 100644
--- a/sd/source/ui/docshell/docshel2.cxx
+++ b/sd/source/ui/docshell/docshel2.cxx
@@ -76,7 +76,7 @@ void DrawDocShell::Draw(OutputDevice* pOut, const JobSetup&, sal_uInt16 nAspect)
if( nullptr == pSelectedPage )
{
SdPage* pPage = nullptr;
- sal_uInt16 nPageCnt = (sal_uInt16) mpDoc->GetSdPageCount(PageKind::Standard);
+ sal_uInt16 nPageCnt = mpDoc->GetSdPageCount(PageKind::Standard);
for (sal_uInt16 i = 0; i < nPageCnt; i++)
{
diff --git a/sd/source/ui/func/futext.cxx b/sd/source/ui/func/futext.cxx
index 3b6757000e77..9b7bbb1558d2 100644
--- a/sd/source/ui/func/futext.cxx
+++ b/sd/source/ui/func/futext.cxx
@@ -240,7 +240,7 @@ void FuText::DoExecute( SfxRequest& )
&& SID_TEXTEDIT == nSlotId
&& SfxItemState::SET == pArgs->GetItemState(SID_TEXTEDIT)
- && (sal_uInt16)static_cast<const SfxUInt16Item&>(pArgs->Get(SID_TEXTEDIT)).GetValue() == 2)
+ && static_cast<const SfxUInt16Item&>(pArgs->Get(SID_TEXTEDIT)).GetValue() == 2)
{
// Selection by doubleclick -> don't allow QuickDrag
bQuickDrag = false;
@@ -1273,7 +1273,7 @@ void FuText::ReceiveRequest(SfxRequest& rReq)
&& SID_TEXTEDIT == nSlotId
&& SfxItemState::SET == pArgs->GetItemState(SID_TEXTEDIT)
- && (sal_uInt16) static_cast<const SfxUInt16Item&>( pArgs->Get(SID_TEXTEDIT)).GetValue() == 2)
+ && static_cast<const SfxUInt16Item&>( pArgs->Get(SID_TEXTEDIT)).GetValue() == 2)
{
// selection wit double click -> do not allow QuickDrag
bQuickDrag = false;
diff --git a/sd/source/ui/unoidl/unomodel.cxx b/sd/source/ui/unoidl/unomodel.cxx
index d86f4a9a7def..ba51319c0108 100644
--- a/sd/source/ui/unoidl/unomodel.cxx
+++ b/sd/source/ui/unoidl/unomodel.cxx
@@ -1332,7 +1332,7 @@ uno::Any SAL_CALL SdXImpressDocument::getPropertyValue( const OUString& Property
sal_Int16 nMeasureUnit = 0;
SvxMapUnitToMeasureUnit( pEmbeddedObj->GetMapUnit(), nMeasureUnit );
- aAny <<= (sal_Int16)nMeasureUnit;
+ aAny <<= nMeasureUnit;
}
break;
case WID_MODEL_FORBCHARS:
diff --git a/sd/source/ui/unoidl/unopage.cxx b/sd/source/ui/unoidl/unopage.cxx
index 3b7eb5c0d81c..785c771c27af 100644
--- a/sd/source/ui/unoidl/unopage.cxx
+++ b/sd/source/ui/unoidl/unopage.cxx
... etc. - the rest is truncated
More information about the Libreoffice-commits
mailing list