summaryrefslogtreecommitdiff
path: root/sd
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2014-09-25 20:16:26 +0200
committerNoel Grandin <noel@peralex.com>2014-09-26 15:27:17 +0200
commit04fd62096fca2c0b917ac6172104399e65933585 (patch)
tree3e1d4e9c8b9aed6b308103c5e235f71ec3b2cce1 /sd
parent5501c8d2220ee3cab703d09d348e99ba3e017dba (diff)
remove unnecessary casts in calls to SvStream.WriteInt32
left over from our conversion of the SvStream output operators to more specific methods Change-Id: I0c0172519479be0535a447e41a592fbf782751bd
Diffstat (limited to 'sd')
-rw-r--r--sd/source/filter/eppt/eppt.cxx20
-rw-r--r--sd/source/filter/eppt/epptso.cxx30
-rw-r--r--sd/source/filter/eppt/escherex.cxx16
-rw-r--r--sd/source/filter/eppt/pptx-stylesheet.cxx2
4 files changed, 34 insertions, 34 deletions
diff --git a/sd/source/filter/eppt/eppt.cxx b/sd/source/filter/eppt/eppt.cxx
index 856a65cdb320..9fbf5a37a257 100644
--- a/sd/source/filter/eppt/eppt.cxx
+++ b/sd/source/filter/eppt/eppt.cxx
@@ -362,7 +362,7 @@ void PPTWriter::ImplWriteSlideMaster( sal_uInt32 nPageNum, Reference< XPropertyS
mpPptEscherEx->PtReplaceOrInsert( EPP_Persist_MainMaster | nPageNum, mpStrm->Tell() );
mpPptEscherEx->OpenContainer( EPP_MainMaster );
mpPptEscherEx->AddAtom( 24, EPP_SlideAtom, 2 );
- mpStrm->WriteInt32( (sal_Int32)EPP_LAYOUT_TITLEANDBODYSLIDE ) // slide layout -> title and body slide
+ mpStrm->WriteInt32( EPP_LAYOUT_TITLEANDBODYSLIDE ) // slide layout -> title and body slide
.WriteUChar( 1 ).WriteUChar( 2 ).WriteUChar( 0 ).WriteUChar( 0 ).WriteUChar( 0 ).WriteUChar( 0 ).WriteUChar( 0 ).WriteUChar( 0 ) // placeholderID
.WriteUInt32( (sal_uInt32)0 ) // master ID (equals null at a master page)
.WriteUInt32( (sal_uInt32)0 ) // notes ID (equals null if no notes are present)
@@ -684,9 +684,9 @@ bool PPTWriter::ImplCreateDocument()
mpPptEscherEx->AddAtom( 40, EPP_DocumentAtom, 1 );
mpStrm->WriteUInt32( nWidth ) // Slide Size in Master coordinates X
.WriteUInt32( nHeight ) // " " " " " Y
- .WriteInt32( (sal_Int32)maNotesPageSize.Width ) // Notes Page Size X
- .WriteInt32( (sal_Int32)maNotesPageSize.Height ) // " " " Y
- .WriteInt32( (sal_Int32)1 ).WriteInt32( (sal_Int32)2 ); // the scale used when the Powerpoint document is embedded. the default is 1:2
+ .WriteInt32( maNotesPageSize.Width ) // Notes Page Size X
+ .WriteInt32( maNotesPageSize.Height ) // " " " Y
+ .WriteInt32( 1 ).WriteInt32( 2 ); // the scale used when the Powerpoint document is embedded. the default is 1:2
mpPptEscherEx->InsertPersistOffset( EPP_MAINNOTESMASTER_PERSIST_KEY, mpStrm->Tell() );
mpStrm->WriteUInt32( (sal_uInt32)0 ) // Reference to NotesMaster ( 0 if none );
.WriteUInt32( (sal_uInt32)0 ) // Reference to HandoutMaster ( 0 if none );
@@ -720,8 +720,8 @@ bool PPTWriter::ImplCreateDocument()
mpPptEscherEx->InsertPersistOffset( EPP_MAINSLIDE_PERSIST_KEY | i, mpStrm->Tell() );
mpStrm->WriteUInt32( (sal_uInt32)0 ) // psrReference - logical reference to the slide persist object ( EPP_MAINSLIDE_PERSIST_KEY )
.WriteUInt32( (sal_uInt32)4 ) // flags - only bit 3 used, if set then slide contains shapes other than placeholders
- .WriteInt32( (sal_Int32)0 ) // numberTexts - number of placeholder texts stored with the persist object. Allows to display outline view without loading the slide persist objects
- .WriteInt32( (sal_Int32)i + 0x100 ) // slideId - Unique slide identifier, used for OLE link monikers for example
+ .WriteInt32( 0 ) // numberTexts - number of placeholder texts stored with the persist object. Allows to display outline view without loading the slide persist objects
+ .WriteInt32( i + 0x100 ) // slideId - Unique slide identifier, used for OLE link monikers for example
.WriteUInt32( (sal_uInt32)0 ); // reserved, usually 0
if ( !GetPageByIndex( i, NORMAL ) ) // very exciting: once again through all pages
@@ -745,8 +745,8 @@ bool PPTWriter::ImplCreateDocument()
mpPptEscherEx->InsertPersistOffset( EPP_MAINNOTES_PERSIST_KEY | i, mpStrm->Tell() );
mpStrm->WriteUInt32( (sal_uInt32)0 )
.WriteUInt32( (sal_uInt32)4 )
- .WriteInt32( (sal_Int32)0 )
- .WriteInt32( (sal_Int32)i + 0x100 )
+ .WriteInt32( 0 )
+ .WriteInt32( i + 0x100 )
.WriteUInt32( (sal_uInt32)0 );
}
mpPptEscherEx->CloseContainer(); // EPP_SlideListWithText
@@ -1289,7 +1289,7 @@ void PPTWriter::ImplWriteOLE( )
xStm->WriteUInt32( (sal_uInt32)0 ) // no ClipboardId
.WriteUInt32( (sal_uInt32)4 ) // no target device
.WriteUInt32( (sal_uInt32)1 ) // aspect ratio
- .WriteInt32( (sal_Int32)-1 ) // L-Index
+ .WriteInt32( -1 ) // L-Index
.WriteUInt32( (sal_uInt32)0 ) // Advanced Flags
.WriteUInt32( (sal_uInt32)0 ) // compression
.WriteUInt32( (sal_uInt32)0 ) // Size
@@ -1431,7 +1431,7 @@ bool PPTWriter::ImplWriteAtomEnding()
mpCurUserStrm->WriteUInt32( (sal_uInt32)nPos ); // set offset to current edit
mpPptEscherEx->AddAtom( 28, EPP_UserEditAtom );
- mpStrm->WriteInt32( (sal_Int32)0x100 ) // last slide ID
+ mpStrm->WriteInt32( 0x100 ) // last slide ID
.WriteUInt32( (sal_uInt32)0x03000dbc ) // minor and major app version that did the save
.WriteUInt32( (sal_uInt32)0 ) // offset last save, 0 after a full save
.WriteUInt32( nPersistOfs ) // File offset to persist pointers for this save operation
diff --git a/sd/source/filter/eppt/epptso.cxx b/sd/source/filter/eppt/epptso.cxx
index b5fce12a4cd6..7ee29aa384c4 100644
--- a/sd/source/filter/eppt/epptso.cxx
+++ b/sd/source/filter/eppt/epptso.cxx
@@ -198,9 +198,9 @@ sal_uInt32 PPTWriter::ImplSlideViewInfoContainer( sal_uInt32 nInstance, SvStream
.WriteUInt32( (sal_uInt32)( EPP_SlideViewInfoAtom << 16 ) ).WriteUInt32( (sal_uInt32)3 )
.WriteUChar( bShowGuides ).WriteUChar( bSnapToGrid ).WriteUChar( bSnapToShape )
.WriteUInt32( (sal_uInt32)( EPP_ViewInfoAtom << 16 ) ).WriteUInt32( (sal_uInt32)52 )
- .WriteInt32( nScaling ).WriteInt32( (sal_Int32)100 ).WriteInt32( nScaling ).WriteInt32( (sal_Int32)100 ) // scaling atom - Keeps the current scale
- .WriteInt32( nScaling ).WriteInt32( (sal_Int32)100 ).WriteInt32( nScaling ).WriteInt32( (sal_Int32)100 ) // scaling atom - Keeps the previous scale
- .WriteInt32( (sal_Int32)0x17ac ).WriteInt32( nMasterCoordinate )// Origin - Keeps the origin in master coordinates
+ .WriteInt32( nScaling ).WriteInt32( 100 ).WriteInt32( nScaling ).WriteInt32( 100 ) // scaling atom - Keeps the current scale
+ .WriteInt32( nScaling ).WriteInt32( 100 ).WriteInt32( nScaling ).WriteInt32( 100 ) // scaling atom - Keeps the previous scale
+ .WriteInt32( 0x17ac ).WriteInt32( nMasterCoordinate )// Origin - Keeps the origin in master coordinates
.WriteInt32( nXOrigin ).WriteInt32( nYOrigin ) // Origin
.WriteUChar( 1 ) // Bool1 varScale - Set if zoom to fit is set
.WriteUChar( 0 ) // bool1 draftMode - Not used
@@ -209,7 +209,7 @@ sal_uInt32 PPTWriter::ImplSlideViewInfoContainer( sal_uInt32 nInstance, SvStream
.WriteUInt32( (sal_uInt32)0 ) // Type of the guide. If the guide is horizontal this value is zero. If it's vertical, it's one.
.WriteInt32( nPosition1 ) // Position of the guide in master coordinates. X coordinate if it's vertical, and Y coordinate if it's horizontal.
.WriteUInt32( (sal_uInt32)( ( 7 << 4 ) | ( EPP_GuideAtom << 16 ) ) ).WriteUInt32( (sal_uInt32)8 )
- .WriteInt32( (sal_Int32)1 ) // Type of the guide. If the guide is horizontal this value is zero. If it's vertical, it's one.
+ .WriteInt32( 1 ) // Type of the guide. If the guide is horizontal this value is zero. If it's vertical, it's one.
.WriteInt32( nPosition2 ); // Position of the guide in master coordinates. X coordinate if it's vertical, and Y coordinate if it's horizontal.
}
return nSize;
@@ -222,10 +222,10 @@ sal_uInt32 PPTWriter::ImplOutlineViewInfoContainer( SvStream* pStrm )
{
pStrm->WriteUInt32( (sal_uInt32)( 0xf | ( EPP_OutlineViewInfo << 16 ) ) ).WriteUInt32( (sal_uInt32)( nSize - 8 ) )
.WriteUInt32( (sal_uInt32)( EPP_ViewInfoAtom << 16 ) ).WriteUInt32( (sal_uInt32)52 )
- .WriteInt32( (sal_Int32)170 ).WriteInt32( (sal_Int32)200 ).WriteInt32( (sal_Int32)170 ).WriteInt32( (sal_Int32)200 ) // scaling atom - Keeps the current scale
- .WriteInt32( (sal_Int32)170 ).WriteInt32( (sal_Int32)200 ).WriteInt32( (sal_Int32)170 ).WriteInt32( (sal_Int32)200 ) // scaling atom - Keeps the previous scale
- .WriteInt32( (sal_Int32)0x17ac ).WriteInt32( (sal_Int32)0xdda ) // Origin - Keeps the origin in master coordinates
- .WriteInt32( (sal_Int32)-780 ).WriteInt32( (sal_Int32)-84 ) // Origin
+ .WriteInt32( 170 ).WriteInt32( 200 ).WriteInt32( 170 ).WriteInt32( 200 ) // scaling atom - Keeps the current scale
+ .WriteInt32( 170 ).WriteInt32( 200 ).WriteInt32( 170 ).WriteInt32( 200 ) // scaling atom - Keeps the previous scale
+ .WriteInt32( 0x17ac ).WriteInt32( 0xdda ) // Origin - Keeps the origin in master coordinates
+ .WriteInt32( -780 ).WriteInt32( -84 ) // Origin
.WriteUChar( 1 ) // bool1 varScale - Set if zoom to fit is set
.WriteUChar( 0 ) // bool1 draftMode - Not used
.WriteUInt16( 0 ); // padword
@@ -348,8 +348,8 @@ sal_uInt32 PPTWriter::ImplMasterSlideListContainer( SvStream* pStrm )
mpPptEscherEx->InsertPersistOffset( EPP_MAINMASTER_PERSIST_KEY | i, pStrm->Tell() );
pStrm->WriteUInt32( (sal_uInt32)0 ) // psrReference - logical reference to the slide persist object ( EPP_MAINMASTER_PERSIST_KEY )
.WriteUInt32( (sal_uInt32)0 ) // flags - only bit 3 used, if set then slide contains shapes other than placeholders
- .WriteInt32( (sal_Int32)0 ) // numberTexts - number of placeholder texts stored with the persist object. Allows to display outline view without loading the slide persist objects
- .WriteInt32( (sal_Int32)( 0x80000000 | i ) ) // slideId - Unique slide identifier, used for OLE link monikers for example
+ .WriteInt32( 0 ) // numberTexts - number of placeholder texts stored with the persist object. Allows to display outline view without loading the slide persist objects
+ .WriteInt32( ( 0x80000000 | i ) ) // slideId - Unique slide identifier, used for OLE link monikers for example
.WriteUInt32( (sal_uInt32)0 ); // reserved, usually 0
}
}
@@ -461,7 +461,7 @@ bool PPTWriter::ImplCloseDocument()
// Open Container ( EPP_SrKinsoku )
mpStrm->WriteUInt16( 0x2f ).WriteUInt16( EPP_SrKinsoku ).WriteUInt32( (sal_uInt32)12 );
mpPptEscherEx->AddAtom( 4, EPP_SrKinsokuAtom, 0, 3 );
- mpStrm->WriteInt32( (sal_Int32)0 ); // SrKinsoku Level 0
+ mpStrm->WriteInt32( 0 ); // SrKinsoku Level 0
// Open Container ( EPP_FontCollection )
mpStrm->WriteUInt16( 0xf ).WriteUInt16( EPP_FontCollection ).WriteUInt32( (sal_uInt32)maFontCollection.GetCount() * 76 );
@@ -3618,10 +3618,10 @@ void PPTWriter::ImplCreateTable( uno::Reference< drawing::XShape >& rXShape, Esc
mpPptEscherEx->OpenContainer( ESCHER_SpgrContainer );
mpPptEscherEx->OpenContainer( ESCHER_SpContainer );
mpPptEscherEx->AddAtom( 16, ESCHER_Spgr, 1 );
- mpStrm ->WriteInt32( (sal_Int32)maRect.Left() ) // Bounding box for the grouped shapes to which they are attached
- .WriteInt32( (sal_Int32)maRect.Top() )
- .WriteInt32( (sal_Int32)maRect.Right() )
- .WriteInt32( (sal_Int32)maRect.Bottom() );
+ mpStrm ->WriteInt32( maRect.Left() ) // Bounding box for the grouped shapes to which they are attached
+ .WriteInt32( maRect.Top() )
+ .WriteInt32( maRect.Right() )
+ .WriteInt32( maRect.Bottom() );
sal_uInt32 nShapeId = mpPptEscherEx->GenerateShapeId();
mpPptEscherEx->AddShape( ESCHER_ShpInst_Min, 0x201, nShapeId ); // Flags: Group | Patriarch
diff --git a/sd/source/filter/eppt/escherex.cxx b/sd/source/filter/eppt/escherex.cxx
index 8a7794ef4830..a796dd688daf 100644
--- a/sd/source/filter/eppt/escherex.cxx
+++ b/sd/source/filter/eppt/escherex.cxx
@@ -220,10 +220,10 @@ sal_uInt32 PptEscherEx::EnterGroup( Rectangle* pBoundRect, SvMemoryStream* pClie
OpenContainer( ESCHER_SpContainer );
AddAtom( 16, ESCHER_Spgr, 1 );
PtReplaceOrInsert( ESCHER_Persist_Grouping_Snap | mnGroupLevel, mpOutStrm->Tell() );
- mpOutStrm ->WriteInt32( (sal_Int32)aRect.Left() ) // bounding box for the grouped shapes to which they are attached
- .WriteInt32( (sal_Int32)aRect.Top() )
- .WriteInt32( (sal_Int32)aRect.Right() )
- .WriteInt32( (sal_Int32)aRect.Bottom() );
+ mpOutStrm ->WriteInt32( aRect.Left() ) // bounding box for the grouped shapes to which they are attached
+ .WriteInt32( aRect.Top() )
+ .WriteInt32( aRect.Right() )
+ .WriteInt32( aRect.Bottom() );
nShapeId = GenerateShapeId();
if ( !mnGroupLevel )
@@ -241,10 +241,10 @@ sal_uInt32 PptEscherEx::EnterGroup( Rectangle* pBoundRect, SvMemoryStream* pClie
{
AddAtom( 16, ESCHER_ChildAnchor );
PtReplaceOrInsert( ESCHER_Persist_Grouping_Snap | mnGroupLevel, mpOutStrm->Tell() );
- mpOutStrm ->WriteInt32( (sal_Int32)aRect.Left() )
- .WriteInt32( (sal_Int32)aRect.Top() )
- .WriteInt32( (sal_Int32)aRect.Right() )
- .WriteInt32( (sal_Int32)aRect.Bottom() );
+ mpOutStrm ->WriteInt32( aRect.Left() )
+ .WriteInt32( aRect.Top() )
+ .WriteInt32( aRect.Right() )
+ .WriteInt32( aRect.Bottom() );
}
}
if ( pClientData )
diff --git a/sd/source/filter/eppt/pptx-stylesheet.cxx b/sd/source/filter/eppt/pptx-stylesheet.cxx
index 56706e1b5ab2..9152d9e99a0c 100644
--- a/sd/source/filter/eppt/pptx-stylesheet.cxx
+++ b/sd/source/filter/eppt/pptx-stylesheet.cxx
@@ -488,7 +488,7 @@ void PPTExStyleSheet::WriteTxCFStyleAtom( SvStream& rSt )
.WriteUInt16( ( 0x80 | nCharFlags ) )
.WriteUInt16( nFlags )
.WriteUInt16( nCharFlags )
- .WriteInt32( (sal_Int32)-1 ) // ?
+ .WriteInt32( -1 ) // ?
.WriteUInt16( rCharStyle.mnFontHeight )
.WriteUInt32( rCharStyle.mnFontColor );
}