diff options
author | Noel Grandin <noel@peralex.com> | 2013-10-07 14:55:43 +0200 |
---|---|---|
committer | Noel Grandin <noel@peralex.com> | 2013-10-08 10:03:14 +0200 |
commit | 062560f065887ffbbf0e0eab0893c7dcccb82a00 (patch) | |
tree | e2316f614f32150f138c6eab14fa6da633e52373 | |
parent | bac9d53c92c83c03e2a7478567f5dfe7d2446e99 (diff) |
convert sc/source/filter/dif/*.cxx from String to OUString
Change-Id: I01e17e2f3d7486b60c85fa3c90e50e8804c07d92
-rw-r--r-- | sc/source/filter/dif/difexp.cxx | 10 | ||||
-rw-r--r-- | sc/source/filter/dif/difimp.cxx | 4 |
2 files changed, 6 insertions, 8 deletions
diff --git a/sc/source/filter/dif/difexp.cxx b/sc/source/filter/dif/difexp.cxx index 91d6f9f70414..44a89bcdff12 100644 --- a/sc/source/filter/dif/difexp.cxx +++ b/sc/source/filter/dif/difexp.cxx @@ -224,16 +224,16 @@ FltError ScFormatFilterPluginImpl::ScExportDif( SvStream& rOut, ScDocument* pDoc // In fact we should create a common method if this would be // needed just one more time.. OSL_ASSERT(aOS.getLength() == 0); - String aTmpStr = aString; + OUString aTmpStr = aString; aOS.appendAscii(pStringData); rOut.WriteUnicodeOrByteText(aOS.makeStringAndClear(), eCharSet); if ( eCharSet == RTL_TEXTENCODING_UNICODE ) { - xub_StrLen nPos = aTmpStr.Search( cStrDelim ); - while ( nPos != STRING_NOTFOUND ) + sal_Int32 nPos = aTmpStr.indexOf( cStrDelim ); + while ( nPos != -1 ) { - aTmpStr.Insert( cStrDelim, nPos ); - nPos = aTmpStr.Search( cStrDelim, nPos+2 ); + aTmpStr = aTmpStr.replaceAt( nPos, 0, OUString(cStrDelim) ); + nPos = aTmpStr.indexOf( cStrDelim, nPos+2 ); } rOut.WriteUniOrByteChar( cStrDelim, eCharSet ); write_uInt16s_FromOUString(rOut, aTmpStr); diff --git a/sc/source/filter/dif/difimp.cxx b/sc/source/filter/dif/difimp.cxx index feab9741c1b4..fd9447d3d84b 100644 --- a/sc/source/filter/dif/difimp.cxx +++ b/sc/source/filter/dif/difimp.cxx @@ -182,9 +182,7 @@ FltError ScFormatFilterPluginImpl::ScImportDif( SvStream& rIn, ScDocument* pDoc, } else { - String aTmp( RTL_CONSTASCII_USTRINGPARAM( "#IND: " )); - aTmp += aData; - aTmp += sal_Unicode('?'); + OUString aTmp = "#IND:" + aData + "?"; pDoc->SetString(aPos, aTmp, &aStrParam); } } |