diff options
author | Noel Grandin <noel@peralex.com> | 2014-01-30 13:46:42 +0200 |
---|---|---|
committer | Michael Stahl <mstahl@redhat.com> | 2014-02-04 22:50:39 +0000 |
commit | 186b4ebc99a2e80740fee51f9d0276886a003617 (patch) | |
tree | a86a4ff5fe3cd36add7053212ef37531540be253 /editeng | |
parent | 95a7e952552adb834f92d1477f83938e7c8d0204 (diff) |
convert specialised SvStream::operator>> methods to ReadXXX methods
as preparation for converting the SvStream::operator>> methods on
primitive types
Change-Id: I62f134bced15c687d6e0d46924f56e8d1c3d95b9
Reviewed-on: https://gerrit.libreoffice.org/7798
Tested-by: LibreOffice gerrit bot <gerrit@libreoffice.org>
Reviewed-by: Michael Stahl <mstahl@redhat.com>
Diffstat (limited to 'editeng')
-rw-r--r-- | editeng/source/items/bulitem.cxx | 2 | ||||
-rw-r--r-- | editeng/source/items/frmitems.cxx | 16 | ||||
-rw-r--r-- | editeng/source/items/numitem.cxx | 6 | ||||
-rw-r--r-- | editeng/source/items/textitem.cxx | 5 |
4 files changed, 16 insertions, 13 deletions
diff --git a/editeng/source/items/bulitem.cxx b/editeng/source/items/bulitem.cxx index 321907f9c5cd..d7af9a2e584b 100644 --- a/editeng/source/items/bulitem.cxx +++ b/editeng/source/items/bulitem.cxx @@ -65,7 +65,7 @@ Font SvxBulletItem::CreateFont( SvStream& rStream, sal_uInt16 nVer ) { Font aFont; Color aColor; - rStream >> aColor; aFont.SetColor( aColor ); + ReadColor( rStream, aColor ); aFont.SetColor( aColor ); sal_uInt16 nTemp; rStream >> nTemp; aFont.SetFamily((FontFamily)nTemp); diff --git a/editeng/source/items/frmitems.cxx b/editeng/source/items/frmitems.cxx index 213fd8bff71b..8c7c25c8ba85 100644 --- a/editeng/source/items/frmitems.cxx +++ b/editeng/source/items/frmitems.cxx @@ -125,7 +125,7 @@ namespace sal_uInt16 nOutline, nInline, nDistance; sal_uInt16 nStyle = NONE; Color aColor; - stream >> aColor >> nOutline >> nInline >> nDistance; + ReadColor( stream, aColor ) >> nOutline >> nInline >> nDistance; if (version >= BORDER_LINE_WITH_STYLE_VERSION) stream >> nStyle; @@ -1571,7 +1571,9 @@ SfxPoolItem* SvxShadowItem::Create( SvStream& rStrm, sal_uInt16 ) const Color aFillColor; sal_Int8 nStyle; rStrm >> cLoc >> _nWidth - >> bTrans >> aColor >> aFillColor >> nStyle; + >> bTrans; + ReadColor( rStrm, aColor ); + ReadColor( rStrm, aFillColor ) >> nStyle; aColor.SetTransparency(bTrans ? 0xff : 0); return new SvxShadowItem( Which(), &aColor, _nWidth, (SvxShadowLocation)cLoc ); } @@ -2690,7 +2692,7 @@ SfxPoolItem* SvxBoxInfoItem::Create( SvStream& rStrm, sal_uInt16 ) const break; short nOutline, nInline, nDistance; Color aColor; - rStrm >> aColor >> nOutline >> nInline >> nDistance; + ReadColor( rStrm, aColor ) >> nOutline >> nInline >> nDistance; SvxBorderLine aBorder( &aColor ); aBorder.GuessLinesWidths(NONE, nOutline, nInline, nDistance); @@ -3319,7 +3321,7 @@ SfxPoolItem* SvxLineItem::Create( SvStream& rStrm, sal_uInt16 ) const short nOutline, nInline, nDistance; Color aColor; - rStrm >> aColor >> nOutline >> nInline >> nDistance; + ReadColor( rStrm, aColor ) >> nOutline >> nInline >> nDistance; if( nOutline ) { SvxBorderLine aLine( &aColor ); @@ -3477,8 +3479,8 @@ SvxBrushItem::SvxBrushItem( SvStream& rStream, sal_uInt16 nVersion, sal_Int8 nStyle; rStream >> bTrans; - rStream >> aTempColor; - rStream >> aTempFillColor; + ReadColor( rStream, aTempColor ); + ReadColor( rStream, aTempFillColor ); rStream >> nStyle; switch ( nStyle ) @@ -3538,7 +3540,7 @@ SvxBrushItem::SvxBrushItem( SvStream& rStream, sal_uInt16 nVersion, { Graphic aGraphic; - rStream >> aGraphic; + ReadGraphic( rStream, aGraphic ); pImpl->pGraphicObject = new GraphicObject( aGraphic ); if( SVSTREAM_FILEFORMAT_ERROR == rStream.GetError() ) diff --git a/editeng/source/items/numitem.cxx b/editeng/source/items/numitem.cxx index 47bf1e061af5..528142cd9066 100644 --- a/editeng/source/items/numitem.cxx +++ b/editeng/source/items/numitem.cxx @@ -214,12 +214,12 @@ SvxNumberFormat::SvxNumberFormat( SvStream &rStream ) if ( hasBulletFont ) { pBulletFont = new Font( ); - rStream >> *pBulletFont; + ReadFont( rStream, *pBulletFont ); } else pBulletFont = NULL; - rStream >> aGraphicSize; + ReadPair( rStream, aGraphicSize ); - rStream >> nBulletColor; + ReadColor( rStream, nBulletColor ); rStream >> nBulletRelSize; rStream >> nTmp16; SetShowSymbol( nTmp16 ); diff --git a/editeng/source/items/textitem.cxx b/editeng/source/items/textitem.cxx index 28f5f07a10ca..ca05faec0fcd 100644 --- a/editeng/source/items/textitem.cxx +++ b/editeng/source/items/textitem.cxx @@ -1936,7 +1936,7 @@ SvxColorItem::SvxColorItem( SvStream &rStrm, const sal_uInt16 nId ) : SfxPoolItem( nId ) { Color aColor; - rStrm >> aColor; + ReadColor( rStrm, aColor ); mColor = aColor; } @@ -2093,7 +2093,8 @@ SfxPoolItem* SvxCharSetColorItem::Create(SvStream& rStrm, sal_uInt16) const { sal_uInt8 cSet; Color aColor; - rStrm >> cSet >> aColor; + rStrm >> cSet; + ReadColor( rStrm, aColor ); return new SvxCharSetColorItem( aColor, (rtl_TextEncoding)cSet, Which() ); } |