diff options
author | Michael Stahl <mstahl@redhat.com> | 2016-06-03 14:45:59 +0200 |
---|---|---|
committer | Michael Stahl <mstahl@redhat.com> | 2016-06-06 18:09:11 +0000 |
commit | 62d270116bf34778bf581f21b27fa9cdbff7de0e (patch) | |
tree | 0402df0506ab8f6825ef497f27426f01d2e01850 /svx | |
parent | d0bc637426060593046c8d3a4d01d0b05b052cc5 (diff) |
tools: rename SvStream::Read/Write to ReadBytes/WriteBytes
Change-Id: Ib788a30d413436aa03f813aa2fddcbc4d6cd2f9a
Reviewed-on: https://gerrit.libreoffice.org/25972
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Michael Stahl <mstahl@redhat.com>
Diffstat (limited to 'svx')
-rw-r--r-- | svx/source/gallery2/codec.cxx | 4 | ||||
-rw-r--r-- | svx/source/gallery2/galobj.cxx | 2 | ||||
-rw-r--r-- | svx/source/gallery2/galtheme.cxx | 4 | ||||
-rw-r--r-- | svx/source/svdraw/svdotxln.cxx | 2 | ||||
-rw-r--r-- | svx/source/tbxctrls/Palette.cxx | 4 | ||||
-rw-r--r-- | svx/source/xml/xmlgrhlp.cxx | 10 | ||||
-rw-r--r-- | svx/source/xoutdev/_xoutbmp.cxx | 4 |
7 files changed, 15 insertions, 15 deletions
diff --git a/svx/source/gallery2/codec.cxx b/svx/source/gallery2/codec.cxx index 8357be0caa9c..aeb7a5dd0066 100644 --- a/svx/source/gallery2/codec.cxx +++ b/svx/source/gallery2/codec.cxx @@ -97,7 +97,7 @@ void GalleryCodec::Read( SvStream& rStmToRead ) if( 1 == nVersion ) { std::unique_ptr<sal_uInt8[]> pCompressedBuffer(new sal_uInt8[ nCompressedSize ]); - rStm.Read( pCompressedBuffer.get(), nCompressedSize ); + rStm.ReadBytes(pCompressedBuffer.get(), nCompressedSize); sal_uInt8* pInBuf = pCompressedBuffer.get(); std::unique_ptr<sal_uInt8[]> pOutBuf(new sal_uInt8[ nUnCompressedSize ]); sal_uInt8* pTmpBuf = pOutBuf.get(); @@ -137,7 +137,7 @@ void GalleryCodec::Read( SvStream& rStmToRead ) } while ( !bEndDecoding && ( pTmpBuf <= pLast ) ); - rStmToRead.Write( pOutBuf.get(), nUnCompressedSize ); + rStmToRead.WriteBytes(pOutBuf.get(), nUnCompressedSize); } else if( 2 == nVersion ) { diff --git a/svx/source/gallery2/galobj.cxx b/svx/source/gallery2/galobj.cxx index d83c1e747960..d4fc256e6ad1 100644 --- a/svx/source/gallery2/galobj.cxx +++ b/svx/source/gallery2/galobj.cxx @@ -297,7 +297,7 @@ void SgaObjectBmp::WriteData( SvStream& rOut, const OUString& rDestDir ) const // Set version SgaObject::WriteData( rOut, rDestDir ); char aDummy[ 10 ]; - rOut.Write( aDummy, 10 ); + rOut.WriteBytes(aDummy, 10); write_uInt16_lenPrefixed_uInt8s_FromOString(rOut, OString()); //dummy write_uInt16_lenPrefixed_uInt8s_FromOUString(rOut, aTitle, RTL_TEXTENCODING_UTF8); } diff --git a/svx/source/gallery2/galtheme.cxx b/svx/source/gallery2/galtheme.cxx index 02b3f3c3daa7..baa7ee1927c2 100644 --- a/svx/source/gallery2/galtheme.cxx +++ b/svx/source/gallery2/galtheme.cxx @@ -901,7 +901,7 @@ bool GalleryTheme::InsertGraphic( const Graphic& rGraphic, sal_uIntPtr nInsertPo { if( aGfxLink.GetDataSize() && aGfxLink.GetData() ) { - pOStm->Write( aGfxLink.GetData(), aGfxLink.GetDataSize() ); + pOStm->WriteBytes(aGfxLink.GetData(), aGfxLink.GetDataSize()); bRet = ( pOStm->GetError() == ERRCODE_NONE ); } else @@ -1360,7 +1360,7 @@ SvStream& GalleryTheme::WriteData( SvStream& rOStm ) const { std::unique_ptr<char[]> pReserve(new char[ nRest ]); memset( pReserve.get(), 0, nRest ); - rOStm.Write( pReserve.get(), nRest ); + rOStm.WriteBytes(pReserve.get(), nRest); } return rOStm; diff --git a/svx/source/svdraw/svdotxln.cxx b/svx/source/svdraw/svdotxln.cxx index 6ced8dc58c7f..b6846dbd81d3 100644 --- a/svx/source/svdraw/svdotxln.cxx +++ b/svx/source/svdraw/svdotxln.cxx @@ -227,7 +227,7 @@ bool SdrTextObj::LoadText(const OUString& rFileName, const OUString& /*rFilterNa char cRTF[5]; cRTF[4] = 0; - pIStm->Read(cRTF, 5); + pIStm->ReadBytes(cRTF, 5); bool bRTF = cRTF[0] == '{' && cRTF[1] == '\\' && cRTF[2] == 'r' && cRTF[3] == 't' && cRTF[4] == 'f'; diff --git a/svx/source/tbxctrls/Palette.cxx b/svx/source/tbxctrls/Palette.cxx index d5e2dd9b9505..9a5c76a7e610 100644 --- a/svx/source/tbxctrls/Palette.cxx +++ b/svx/source/tbxctrls/Palette.cxx @@ -78,7 +78,7 @@ void PaletteASE::LoadPalette() // Verify magic first 4 characters sal_Char cMagic[5] = {0}; - if ((aFile.Read(cMagic, 4) != 4) || (strncmp(cMagic, "ASEF", 4) != 0)) + if ((aFile.ReadBytes(cMagic, 4) != 4) || (strncmp(cMagic, "ASEF", 4) != 0)) { mbValidPalette = false; return; @@ -120,7 +120,7 @@ void PaletteASE::LoadPalette() } sal_Char cColorModel[5] = {0}; - aFile.Read(cColorModel, 4); + aFile.ReadBytes(cColorModel, 4); OString aColorModel(cColorModel); // r, g, and b are floats ranging from 0 to 1 float r = 0, g = 0, b = 0; diff --git a/svx/source/xml/xmlgrhlp.cxx b/svx/source/xml/xmlgrhlp.cxx index 9759e388aa8c..6422c161319e 100644 --- a/svx/source/xml/xmlgrhlp.cxx +++ b/svx/source/xml/xmlgrhlp.cxx @@ -114,7 +114,7 @@ SvXMLGraphicInputStream::SvXMLGraphicInputStream( const OUString& rGraphicId ) if( aGfxLink.GetDataSize() && aGfxLink.GetData() ) { - pStm->Write( aGfxLink.GetData(), aGfxLink.GetDataSize() ); + pStm->WriteBytes(aGfxLink.GetData(), aGfxLink.GetDataSize()); bRet = ( pStm->GetError() == 0 ); } else @@ -310,7 +310,7 @@ const GraphicObject& SvXMLGraphicOutputStream::GetGraphicObject() if( nStreamLen >= 2 ) { //read two byte - mpOStm->Read( sFirstBytes, 2 ); + mpOStm->ReadBytes(sFirstBytes, 2); if( sFirstBytes[0] == 0x1f && sFirstBytes[1] == 0x8b ) { @@ -563,7 +563,7 @@ bool SvXMLGraphicHelper::ImplWriteGraphic( const OUString& rPictureStorageName, std::unique_ptr<SvStream> pStream(utl::UcbStreamHelper::CreateStream( aStream.xStream )); if( bUseGfxLink && aGfxLink.GetDataSize() && aGfxLink.GetData() ) - pStream->Write( aGfxLink.GetData(), aGfxLink.GetDataSize() ); + pStream->WriteBytes(aGfxLink.GetData(), aGfxLink.GetDataSize()); else { if( aGraphic.GetType() == GraphicType::Bitmap ) @@ -592,12 +592,12 @@ bool SvXMLGraphicHelper::ImplWriteGraphic( const OUString& rPictureStorageName, sal_uInt32 nSize = pComment->GetDataSize(); const sal_uInt8* pData = pComment->GetData(); if ( nSize && pData ) - pStream->Write( pData, nSize ); + pStream->WriteBytes(pData, nSize); const MetaEPSAction* pAct = static_cast<const MetaEPSAction*>(rMtf.FirstAction()); const GfxLink& rLink = pAct->GetLink(); - pStream->Write( rLink.GetData(), rLink.GetDataSize() ); + pStream->WriteBytes(rLink.GetData(), rLink.GetDataSize()); } else rMtf.Write( *pStream ); diff --git a/svx/source/xoutdev/_xoutbmp.cxx b/svx/source/xoutdev/_xoutbmp.cxx index bbd06531fc45..7dea7331395d 100644 --- a/svx/source/xoutdev/_xoutbmp.cxx +++ b/svx/source/xoutdev/_xoutbmp.cxx @@ -162,7 +162,7 @@ sal_uInt16 XOutBitmap::WriteGraphic( const Graphic& rGraphic, OUString& rFileNam if(pOStm) { - pOStm->Write(aSvgDataPtr->getSvgDataArray().getConstArray(), aSvgDataPtr->getSvgDataArrayLength()); + pOStm->WriteBytes(aSvgDataPtr->getSvgDataArray().getConstArray(), aSvgDataPtr->getSvgDataArrayLength()); aMedium.Commit(); if(!aMedium.GetError()) @@ -207,7 +207,7 @@ sal_uInt16 XOutBitmap::WriteGraphic( const Graphic& rGraphic, OUString& rFileNam if( pOStm && aGfxLink.GetDataSize() && aGfxLink.GetData() ) { - pOStm->Write( aGfxLink.GetData(), aGfxLink.GetDataSize() ); + pOStm->WriteBytes(aGfxLink.GetData(), aGfxLink.GetDataSize()); aMedium.Commit(); if( !aMedium.GetError() ) |