diff options
Diffstat (limited to 'sdext/source')
-rw-r--r-- | sdext/source/minimizer/pppoptimizerdialog.cxx | 11 | ||||
-rw-r--r-- | sdext/source/pdfimport/odf/odfemitter.cxx | 17 | ||||
-rw-r--r-- | sdext/source/pdfimport/test/pdfunzip.cxx | 20 |
3 files changed, 23 insertions, 25 deletions
diff --git a/sdext/source/minimizer/pppoptimizerdialog.cxx b/sdext/source/minimizer/pppoptimizerdialog.cxx index 66efb3e29824..1bd04455a258 100644 --- a/sdext/source/minimizer/pppoptimizerdialog.cxx +++ b/sdext/source/minimizer/pppoptimizerdialog.cxx @@ -112,12 +112,11 @@ void SAL_CALL PPPOptimizerDialog::dispatch( const URL& rURL, if ( nFileSizeSource && nFileSizeDest ) { - OUStringBuffer sBuf( "Your Presentation has been minimized from:" ); - sBuf.append( OUString::number( nFileSizeSource >> 10 ) ); - sBuf.append( "KB to " ); - sBuf.append( OUString::number( nFileSizeDest >> 10 ) ); - sBuf.append( "KB." ); - OUString sResult( sBuf.makeStringAndClear() ); + OUString sResult = "Your Presentation has been minimized from:" + + OUString::number( nFileSizeSource >> 10 ) + + "KB to " + + OUString::number( nFileSizeDest >> 10 ) + + "KB."; SAL_INFO("sdext.minimizer", sResult ); } } diff --git a/sdext/source/pdfimport/odf/odfemitter.cxx b/sdext/source/pdfimport/odf/odfemitter.cxx index 78a38e42502f..a46d73ac9346 100644 --- a/sdext/source/pdfimport/odf/odfemitter.cxx +++ b/sdext/source/pdfimport/odf/odfemitter.cxx @@ -56,9 +56,8 @@ OdfEmitter::OdfEmitter( const uno::Reference<io::XOutputStream>& xOutput ) : OSL_PRECOND(m_xOutput.is(), "OdfEmitter(): invalid output stream"); m_aLineFeed[0] = '\n'; - OUStringBuffer aElement; - aElement.append("<?xml version=\"1.0\" encoding=\"UTF-8\"?>"); - write(aElement.makeStringAndClear()); + OUString aElement = "<?xml version=\"1.0\" encoding=\"UTF-8\"?>"; + write(aElement); } void OdfEmitter::beginTag( const char* pTag, const PropertyMap& rProperties ) @@ -73,12 +72,12 @@ void OdfEmitter::beginTag( const char* pTag, const PropertyMap& rProperties ) std::vector<OUString> aAttributes; for( const auto& rCurr : rProperties ) { - OUStringBuffer aAttribute; - aAttribute.append(rCurr.first); - aAttribute.append("=\""); - aAttribute.append(rCurr.second); - aAttribute.append("\" "); - aAttributes.push_back(aAttribute.makeStringAndClear()); + OUString aAttribute = + rCurr.first + + "=\"" + + rCurr.second + + "\" "; + aAttributes.push_back(aAttribute); } // since the hash map's sorting is undefined (and varies across diff --git a/sdext/source/pdfimport/test/pdfunzip.cxx b/sdext/source/pdfimport/test/pdfunzip.cxx index a014fa4ccae0..e2a6602ad74a 100644 --- a/sdext/source/pdfimport/test/pdfunzip.cxx +++ b/sdext/source/pdfimport/test/pdfunzip.cxx @@ -263,11 +263,11 @@ static int write_addStreamArray( const char* pOutFile, PDFArray* pStreams, PDFFi PDFObject* pObject = pPDFFile->findObject( pStreamRef->m_nNumber, pStreamRef->m_nGeneration ); if( pObject ) { - OStringBuffer aOutStream( pOutFile ); - aOutStream.append( "_stream_" ); - aOutStream.append( sal_Int32(pStreamRef->m_nNumber) ); - aOutStream.append( "_" ); - aOutStream.append( sal_Int32(pStreamRef->m_nGeneration) ); + OString aOutStream = pOutFile + + OStringLiteral("_stream_") + + OString::number( sal_Int32(pStreamRef->m_nNumber) ) + + "_" + + OString::number( sal_Int32(pStreamRef->m_nGeneration) ); FileEmitContext aContext( aOutStream.getStr(), pInFile, pPDFFile ); aContext.m_bDecrypt = pPDFFile->isEncrypted(); pObject->writeStream( aContext, pPDFFile ); @@ -406,11 +406,11 @@ static int write_objects( const char* i_pInFile, const char* i_pOutFile, PDFFile continue; } - OStringBuffer aOutStream( i_pOutFile ); - aOutStream.append( "_stream_" ); - aOutStream.append( nObject ); - aOutStream.append( "_" ); - aOutStream.append( nGeneration ); + OString aOutStream = i_pOutFile + + OStringLiteral("_stream_") + + OString::number( nObject ) + + "_" + + OString::number( nGeneration ); FileEmitContext aContext( aOutStream.getStr(), i_pInFile, i_pPDFFile ); aContext.m_bDecrypt = i_pPDFFile->isEncrypted(); pStream->writeStream( aContext, i_pPDFFile ); |