summaryrefslogtreecommitdiff
path: root/svx
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2011-11-09 22:36:22 +0000
committerCaolán McNamara <caolanm@redhat.com>2011-11-10 09:28:39 +0000
commit5dbd8286f4623015d6012d20ad24c301e57ca96f (patch)
tree6db4a82962dd7436aa4dae33c59a5a47559103bf /svx
parent180dcdecac80e87f4984024c24f4beeef9dbf766 (diff)
ByteString->rtl::OString
Diffstat (limited to 'svx')
-rw-r--r--svx/source/gallery2/galobj.cxx4
-rw-r--r--svx/source/unodraw/unoshap2.cxx4
-rw-r--r--svx/source/xml/xmlgrhlp.cxx18
3 files changed, 13 insertions, 13 deletions
diff --git a/svx/source/gallery2/galobj.cxx b/svx/source/gallery2/galobj.cxx
index d86553ace8c8..928e060e338e 100644
--- a/svx/source/gallery2/galobj.cxx
+++ b/svx/source/gallery2/galobj.cxx
@@ -208,8 +208,8 @@ const String SgaObject::GetTitle() const
if ( aReturnValue.GetToken( 0, ':' ).EqualsAscii( "private" ) &&
aResourceName.Len() && ( nResId > 0 ) && ( nResId < 0x10000 ) )
{
- ByteString aMgrName( aResourceName, RTL_TEXTENCODING_UTF8 );
- ResMgr* pResMgr = ResMgr::CreateResMgr( aMgrName.GetBuffer(),
+ rtl::OString aMgrName(rtl::OUStringToOString(aResourceName, RTL_TEXTENCODING_UTF8));
+ ResMgr* pResMgr = ResMgr::CreateResMgr( aMgrName.getStr(),
Application::GetSettings().GetUILocale() );
if ( pResMgr )
{
diff --git a/svx/source/unodraw/unoshap2.cxx b/svx/source/unodraw/unoshap2.cxx
index 8e597f71330a..1dcee2b356b6 100644
--- a/svx/source/unodraw/unoshap2.cxx
+++ b/svx/source/unodraw/unoshap2.cxx
@@ -1529,8 +1529,8 @@ bool SvxGraphicObject::setPropertyValueImpl( const ::rtl::OUString& rName, const
// graphic manager url
aURL = aURL.copy( sizeof( UNO_NAME_GRAPHOBJ_URLPREFIX ) - 1 );
String aTmpStr(aURL);
- ByteString aUniqueID( aTmpStr, RTL_TEXTENCODING_UTF8 );
- GraphicObject aGrafObj( aUniqueID );
+ rtl::OString aUniqueID(rtl::OUStringToOString(aTmpStr, RTL_TEXTENCODING_UTF8));
+ GraphicObject aGrafObj(aUniqueID);
// #101808# since loading a graphic can cause a reschedule of the office
// it is possible that our shape is removed while where in this
diff --git a/svx/source/xml/xmlgrhlp.cxx b/svx/source/xml/xmlgrhlp.cxx
index f7330dc40ec3..7a2f20a3dd22 100644
--- a/svx/source/xml/xmlgrhlp.cxx
+++ b/svx/source/xml/xmlgrhlp.cxx
@@ -29,6 +29,7 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_svx.hxx"
#include <sal/macros.h>
+#include <rtl/strbuf.hxx>
#include <com/sun/star/embed/XTransactedObject.hpp>
#include <com/sun/star/embed/ElementModes.hpp>
#include <com/sun/star/beans/XPropertySet.hpp>
@@ -115,8 +116,7 @@ public:
SvXMLGraphicInputStream::SvXMLGraphicInputStream( const ::rtl::OUString& rGraphicId )
{
- String aGraphicId( rGraphicId );
- GraphicObject aGrfObject( ByteString( aGraphicId, RTL_TEXTENCODING_ASCII_US ) );
+ GraphicObject aGrfObject( rtl::OUStringToOString(rGraphicId, RTL_TEXTENCODING_ASCII_US) );
maTmp.EnableKillingFile();
@@ -584,8 +584,7 @@ sal_Bool SvXMLGraphicHelper::ImplWriteGraphic( const ::rtl::OUString& rPictureSt
const ::rtl::OUString& rGraphicId,
bool bUseGfxLink )
{
- String aGraphicId( rGraphicId );
- GraphicObject aGrfObject( ByteString( aGraphicId, RTL_TEXTENCODING_ASCII_US ) );
+ GraphicObject aGrfObject( rtl::OUStringToOString(rGraphicId, RTL_TEXTENCODING_ASCII_US) );
sal_Bool bRet = sal_False;
if( aGrfObject.GetType() != GRAPHIC_NONE )
@@ -709,7 +708,7 @@ void SvXMLGraphicHelper::ImplInsertGraphicURL( const ::rtl::OUString& rURLStr, s
else
{
const String aGraphicObjectId( aPictureStreamName );
- const ByteString aAsciiObjectID( aGraphicObjectId, RTL_TEXTENCODING_ASCII_US );
+ const rtl::OString aAsciiObjectID(rtl::OUStringToOString(aGraphicObjectId, RTL_TEXTENCODING_ASCII_US));
const GraphicObject aGrfObject( aAsciiObjectID );
if( aGrfObject.GetType() != GRAPHIC_NONE )
{
@@ -802,10 +801,11 @@ void SvXMLGraphicHelper::ImplInsertGraphicURL( const ::rtl::OUString& rURLStr, s
#if OSL_DEBUG_LEVEL > 0
else
{
- ByteString sMessage = "graphic object with ID '";
- sMessage += aAsciiObjectID;
- sMessage += "' has an unknown type";
- OSL_ENSURE( false, sMessage.GetBuffer() );
+ rtl::OStringBuffer sMessage(
+ RTL_CONSTASCII_STRINGPARAM("graphic object with ID '"));
+ sMessage.append(aAsciiObjectID).
+ append(RTL_CONSTASCII_STRINGPARAM("' has an unknown type"));
+ OSL_ENSURE( false, sMessage.getStr() );
}
#endif
}