diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2014-11-06 17:24:13 +0100 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2014-11-06 17:24:13 +0100 |
commit | fc0d57b7aff84f4bdca0a1f201527c265d5f0cf5 (patch) | |
tree | 49a72b76d2d2a92af6371748c19277778159b86d /extensions/source | |
parent | e36dae401fc8963c9a92cb2c11d9b650b943c6d3 (diff) |
Revert "use the new OUString::fromUtf8 method"
This reverts commit 05050cdb23de586870bf479a9df5ced06828d498,
not all places that use e.g. OStringToOUString to convert potential UTF-8
are guaranteed to fulfil the prerequisites necessary to use fromUtf8 (and
some places like e.g. in codemaker are happy with the best-effort effect
of OStringToOUString's OSTRING_TO_OUSTRING_CVTFLAGS).
Diffstat (limited to 'extensions/source')
-rw-r--r-- | extensions/source/bibliography/general.cxx | 4 | ||||
-rw-r--r-- | extensions/source/config/ldap/ldapaccess.cxx | 4 | ||||
-rw-r--r-- | extensions/source/plugin/aqua/macmgr.mm | 2 | ||||
-rw-r--r-- | extensions/source/propctrlr/eventhandler.cxx | 2 | ||||
-rw-r--r-- | extensions/source/propctrlr/pcrcommon.cxx | 2 | ||||
-rw-r--r-- | extensions/source/update/check/download.cxx | 4 |
6 files changed, 9 insertions, 9 deletions
diff --git a/extensions/source/bibliography/general.cxx b/extensions/source/bibliography/general.cxx index cbb952a78e9e..26a2512774e2 100644 --- a/extensions/source/bibliography/general.cxx +++ b/extensions/source/bibliography/general.cxx @@ -448,8 +448,8 @@ uno::Reference< awt::XControlModel > BibGeneralPage::AddXControl( if(xPropInfo->hasPropertyByName(uProp)) { OUString sId = OUString::createFromAscii( INET_HID_SCHEME ); - DBG_ASSERT( INetURLObject( OUString::fromUtf8( sHelpId ) ).GetProtocol() == INET_PROT_NOT_VALID, "Wrong HelpId!" ); - sId += OUString::fromUtf8( sHelpId ); + DBG_ASSERT( INetURLObject( OStringToOUString( sHelpId, RTL_TEXTENCODING_UTF8 ) ).GetProtocol() == INET_PROT_NOT_VALID, "Wrong HelpId!" ); + sId += OStringToOUString( sHelpId, RTL_TEXTENCODING_UTF8 ); xPropSet->setPropertyValue( uProp, makeAny( sId ) ); } diff --git a/extensions/source/config/ldap/ldapaccess.cxx b/extensions/source/config/ldap/ldapaccess.cxx index 333a8bcd4c62..2acd02731973 100644 --- a/extensions/source/config/ldap/ldapaccess.cxx +++ b/extensions/source/config/ldap/ldapaccess.cxx @@ -228,7 +228,7 @@ void LdapConnection::initConnection() data->insert( LdapData::value_type( OStringToOUString(attr, RTL_TEXTENCODING_ASCII_US), - OUString::fromUtf8(*values))); + OStringToOUString(*values, RTL_TEXTENCODING_UTF8))); ldap_value_free(values); } attr = ldap_next_attribute(mConnection, result.msg, ptr); @@ -284,7 +284,7 @@ void LdapConnection::initConnection() #else sal_Char *charsDn = ldap_get_dn(mConnection, entry) ; - userDn = OUString::fromUtf8( charsDn ); + userDn = OStringToOUString( charsDn, RTL_TEXTENCODING_UTF8 ); ldap_memfree(charsDn) ; #endif } diff --git a/extensions/source/plugin/aqua/macmgr.mm b/extensions/source/plugin/aqua/macmgr.mm index c92f4fef92b4..878571a9377e 100644 --- a/extensions/source/plugin/aqua/macmgr.mm +++ b/extensions/source/plugin/aqua/macmgr.mm @@ -283,7 +283,7 @@ static rtl::OUString GetNextPluginStringFromHandle(Handle h, short *index) rtl::OStringBuffer aBuf( nLen ); aBuf.append( pPascalBytes+1, nLen ); *index += nLen + 1; - return rtl::OUString::fromUtf8( aBuf.makeStringAndClear() ); + return rtl::OStringToOUString( aBuf.makeStringAndClear(), RTL_TEXTENCODING_UTF8 ); } static int parseMimeResource( CFBundleRef i_xBundle, diff --git a/extensions/source/propctrlr/eventhandler.cxx b/extensions/source/propctrlr/eventhandler.cxx index fa6f4b0f2ace..34a2dd02f286 100644 --- a/extensions/source/propctrlr/eventhandler.cxx +++ b/extensions/source/propctrlr/eventhandler.cxx @@ -809,7 +809,7 @@ namespace pcr const EventDescription& rEvent = impl_getEventForName_throw( _rPropertyName ); aDescriptor.DisplayName = rEvent.sDisplayName; aDescriptor.HelpURL = HelpIdUrl::getHelpURL( rEvent.sHelpId ); - aDescriptor.PrimaryButtonId = OUString::fromUtf8(rEvent.sUniqueBrowseId); + aDescriptor.PrimaryButtonId = OStringToOUString(rEvent.sUniqueBrowseId, RTL_TEXTENCODING_UTF8); aDescriptor.HasPrimaryButton = sal_True; aDescriptor.Category = "Events"; return aDescriptor; diff --git a/extensions/source/propctrlr/pcrcommon.cxx b/extensions/source/propctrlr/pcrcommon.cxx index 0cd148e722ca..9292a029a4e8 100644 --- a/extensions/source/propctrlr/pcrcommon.cxx +++ b/extensions/source/propctrlr/pcrcommon.cxx @@ -49,7 +49,7 @@ namespace pcr OUString HelpIdUrl::getHelpURL( const OString& sHelpId ) { OUStringBuffer aBuffer; - OUString aTmp( OUString::fromUtf8(sHelpId) ); + OUString aTmp( OStringToOUString(sHelpId, RTL_TEXTENCODING_UTF8) ); INetURLObject aHID( aTmp ); if ( aHID.GetProtocol() == INET_PROT_NOT_VALID ) aBuffer.appendAscii( INET_HID_SCHEME ); diff --git a/extensions/source/update/check/download.cxx b/extensions/source/update/check/download.cxx index 647709e84ce0..ac0c4b7688e1 100644 --- a/extensions/source/update/check/download.cxx +++ b/extensions/source/update/check/download.cxx @@ -77,7 +77,7 @@ static void openFile( OutData& out ) sal_Int32 nIndex = aURL.lastIndexOf('/'); if( nIndex > 0 ) { - out.File = out.DestinationDir + OUString::fromUtf8(aURL.copy(nIndex)); + out.File = out.DestinationDir + OStringToOUString(aURL.copy(nIndex), RTL_TEXTENCODING_UTF8); oslFileError rc; @@ -329,7 +329,7 @@ bool curl_run(const OUString& rURL, OutData& out, const OString& aProxyHost, sal } } if ( !ret ) - out.Handler->downloadStalled( OUString::fromUtf8(aMessage) ); + out.Handler->downloadStalled( OStringToOUString(aMessage, RTL_TEXTENCODING_UTF8) ); } curl_easy_cleanup(pCURL); |