diff options
-rw-r--r-- | editeng/source/editeng/editdbg.cxx | 2 | ||||
-rw-r--r-- | filter/source/msfilter/escherex.cxx | 4 | ||||
-rw-r--r-- | sd/source/filter/eppt/pptx-text.cxx | 2 | ||||
-rw-r--r-- | tools/inc/tools/string.hxx | 3 | ||||
-rw-r--r-- | tools/source/string/strcvt.cxx | 25 |
5 files changed, 4 insertions, 32 deletions
diff --git a/editeng/source/editeng/editdbg.cxx b/editeng/source/editeng/editdbg.cxx index ac7eb920f61e..1f00e90799c2 100644 --- a/editeng/source/editeng/editdbg.cxx +++ b/editeng/source/editeng/editdbg.cxx @@ -413,7 +413,7 @@ void EditDbg::ShowEditEngineData( EditEngine* pEE, sal_Bool bInfoBox ) { EditLine* pLine = pPPortion->GetLines().GetObject( nLine ); - ByteString aLine( *(pPPortion->GetNode()), pLine->GetStart(), pLine->GetEnd() - pLine->GetStart(), RTL_TEXTENCODING_ASCII_US ); + ByteString aLine( pPPortion->GetNode()->Copy(pLine->GetStart(), pLine->GetEnd() - pLine->GetStart()), RTL_TEXTENCODING_ASCII_US ); fprintf( fp, "\nLine %i\t>%s<", nLine, aLine.GetBuffer() ); } // then the internal data ... diff --git a/filter/source/msfilter/escherex.cxx b/filter/source/msfilter/escherex.cxx index 2bd758eb91c6..6ad0a26b15b0 100644 --- a/filter/source/msfilter/escherex.cxx +++ b/filter/source/msfilter/escherex.cxx @@ -1199,7 +1199,7 @@ sal_Bool EscherPropertyContainer::CreateEmbeddedBitmapProperties( nIndex = nIndex + aVndUrl.Len(); if( aBmpUrl.Len() > nIndex ) { - ByteString aUniqueId( aBmpUrl, nIndex, aBmpUrl.Len() - nIndex, RTL_TEXTENCODING_UTF8 ); + ByteString aUniqueId( aBmpUrl.Copy(nIndex, aBmpUrl.Len() - nIndex), RTL_TEXTENCODING_UTF8 ); bRetValue = ImplCreateEmbeddedBmp( aUniqueId ); if( bRetValue ) { @@ -1368,7 +1368,7 @@ sal_Bool EscherPropertyContainer::CreateGraphicProperties( { nIndex = nIndex + aVndUrl.Len(); if ( aGraphicUrl.Len() > nIndex ) - aUniqueId = ByteString( aGraphicUrl, nIndex, aGraphicUrl.Len() - nIndex, RTL_TEXTENCODING_UTF8 ); + aUniqueId = ByteString( aGraphicUrl.Copy(nIndex, aGraphicUrl.Len() - nIndex), RTL_TEXTENCODING_UTF8 ); } else { diff --git a/sd/source/filter/eppt/pptx-text.cxx b/sd/source/filter/eppt/pptx-text.cxx index 8b0b7612ebc6..bf6499ca8f42 100644 --- a/sd/source/filter/eppt/pptx-text.cxx +++ b/sd/source/filter/eppt/pptx-text.cxx @@ -905,7 +905,7 @@ void ParagraphObj::ImplGetNumberingLevel( PPTExBulletProvider& rBuProv, sal_Int1 nIndex++; if ( aGraphicURL.Len() > nIndex ) { - ByteString aUniqueId( aGraphicURL, nIndex, aGraphicURL.Len() - nIndex, RTL_TEXTENCODING_UTF8 ); + ByteString aUniqueId( aGraphicURL.Copy(nIndex, aGraphicURL.Len() - nIndex), RTL_TEXTENCODING_UTF8 ); if ( aUniqueId.Len() ) { nBulletId = rBuProv.GetId( aUniqueId, aBuGraSize ); diff --git a/tools/inc/tools/string.hxx b/tools/inc/tools/string.hxx index a1428a6c2f73..296dc296e72c 100644 --- a/tools/inc/tools/string.hxx +++ b/tools/inc/tools/string.hxx @@ -186,9 +186,6 @@ public: ByteString( const UniString& rUniStr, rtl_TextEncoding eTextEncoding, sal_uInt32 nCvtFlags = UNISTRING_TO_BYTESTRING_CVTFLAGS ); - ByteString( const UniString& rUniStr, xub_StrLen nPos, xub_StrLen nLen, - rtl_TextEncoding eTextEncoding, - sal_uInt32 nCvtFlags = UNISTRING_TO_BYTESTRING_CVTFLAGS ); ByteString( const sal_Unicode* pUniStr, xub_StrLen nLen, rtl_TextEncoding eTextEncoding, sal_uInt32 nCvtFlags = UNISTRING_TO_BYTESTRING_CVTFLAGS ); diff --git a/tools/source/string/strcvt.cxx b/tools/source/string/strcvt.cxx index 22bb517e8582..210636f8073b 100644 --- a/tools/source/string/strcvt.cxx +++ b/tools/source/string/strcvt.cxx @@ -57,31 +57,6 @@ ByteString::ByteString( const UniString& rUniStr, rtl_TextEncoding eTextEncoding // ----------------------------------------------------------------------- -ByteString::ByteString( const UniString& rUniStr, xub_StrLen nPos, xub_StrLen nLen, - rtl_TextEncoding eTextEncoding, sal_uInt32 nCvtFlags ) -{ - DBG_CTOR( ByteString, DbgCheckByteString ); - DBG_CHKOBJ( &rUniStr, UniString, DbgCheckUniString ); - - // Stringlaenge ermitteln - if ( nPos > rUniStr.mpData->mnLen ) - nLen = 0; - else - { - // Laenge korrigieren, wenn noetig - sal_Int32 nMaxLen = rUniStr.mpData->mnLen-nPos; - if ( nLen > nMaxLen ) - nLen = static_cast< xub_StrLen >(nMaxLen); - } - - mpData = NULL; - rtl_uString2String( (rtl_String **)(&mpData), - rUniStr.mpData->maStr+nPos, nLen, - eTextEncoding, nCvtFlags ); -} - -// ----------------------------------------------------------------------- - ByteString::ByteString( const sal_Unicode* pUniStr, xub_StrLen nLen, rtl_TextEncoding eTextEncoding, sal_uInt32 nCvtFlags ) { |