[Libreoffice-commits] .: i18npool/source
Gert Faller
gfaller at kemper.freedesktop.org
Mon Nov 22 08:25:40 PST 2010
i18npool/source/breakiterator/breakiteratorImpl.cxx | 4 -
i18npool/source/breakiterator/xdictionary.cxx | 10 +-
i18npool/source/calendar/calendarImpl.cxx | 6 -
i18npool/source/calendar/calendar_gregorian.cxx | 4 -
i18npool/source/characterclassification/characterclassificationImpl.cxx | 8 +-
i18npool/source/collator/chaptercollator.cxx | 2
i18npool/source/collator/collatorImpl.cxx | 8 +-
i18npool/source/collator/collator_unicode.cxx | 4 -
i18npool/source/defaultnumberingprovider/defaultnumberingprovider.cxx | 38 +++++-----
i18npool/source/indexentry/indexentrysupplier.cxx | 4 -
i18npool/source/indexentry/indexentrysupplier_asian.cxx | 8 +-
i18npool/source/indexentry/indexentrysupplier_default.cxx | 2
i18npool/source/inputchecker/inputsequencechecker.cxx | 2
i18npool/source/localedata/LocaleNode.cxx | 6 -
i18npool/source/localedata/localedata.cxx | 8 +-
i18npool/source/localedata/saxparser.cxx | 6 -
i18npool/source/numberformatcode/numberformatcode.cxx | 2
i18npool/source/ordinalsuffix/ordinalsuffix.cxx | 10 +-
i18npool/source/registerservices/registerservices.cxx | 2
i18npool/source/search/textsearch.cxx | 6 -
i18npool/source/textconversion/textconversionImpl.cxx | 12 +--
i18npool/source/textconversion/textconversion_ko.cxx | 8 +-
i18npool/source/textconversion/textconversion_zh.cxx | 2
i18npool/source/transliteration/transliterationImpl.cxx | 4 -
24 files changed, 83 insertions(+), 83 deletions(-)
New commits:
commit 1046ea3e016130512e3e8dad337063f6d0970724
Author: Gert Faller <gertfaller at aliceadsl.fr>
Date: Mon Nov 22 17:20:34 2010 +0100
RTL_CONSTASCII_USTRINGPARAM in libs-gui 03
diff --git a/i18npool/source/breakiterator/breakiteratorImpl.cxx b/i18npool/source/breakiterator/breakiteratorImpl.cxx
index c47f7be..f49da50 100644
--- a/i18npool/source/breakiterator/breakiteratorImpl.cxx
+++ b/i18npool/source/breakiterator/breakiteratorImpl.cxx
@@ -518,7 +518,7 @@ sal_Bool SAL_CALL BreakIteratorImpl::createLocaleSpecificBreakIterator(const OUS
}
Reference < uno::XInterface > xI = xMSF->createInstance(
- OUString::createFromAscii("com.sun.star.i18n.BreakIterator_") + aLocaleName);
+ OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.i18n.BreakIterator_")) + aLocaleName);
if ( xI.is() ) {
xI->queryInterface( getCppuType((const Reference< XBreakIterator>*)0) ) >>= xBI;
@@ -569,7 +569,7 @@ BreakIteratorImpl::getLocaleSpecificBreakIterator(const Locale& rLocale) throw (
// load service with name <base>_<lang>
createLocaleSpecificBreakIterator(rLocale.Language)) ||
// load default service with name <base>_Unicode
- createLocaleSpecificBreakIterator(OUString::createFromAscii("Unicode"))) {
+ createLocaleSpecificBreakIterator(OUString(RTL_CONSTASCII_USTRINGPARAM("Unicode")))) {
lookupTable.push_back( new lookupTableItem(aLocale, xBI) );
return xBI;
}
diff --git a/i18npool/source/breakiterator/xdictionary.cxx b/i18npool/source/breakiterator/xdictionary.cxx
index f63262b..4f75f63 100644
--- a/i18npool/source/breakiterator/xdictionary.cxx
+++ b/i18npool/source/breakiterator/xdictionary.cxx
@@ -79,15 +79,15 @@ xdictionary::xdictionary(const sal_Char *lang) :
hModule = osl_loadModuleRelative( &thisModule, aBuf.makeStringAndClear().pData, SAL_LOADMODULE_DEFAULT );
if( hModule ) {
sal_IntPtr (*func)();
- func = (sal_IntPtr(*)()) osl_getFunctionSymbol( hModule, OUString::createFromAscii("getExistMark").pData );
+ func = (sal_IntPtr(*)()) osl_getFunctionSymbol( hModule, OUString(RTL_CONSTASCII_USTRINGPARAM("getExistMark")).pData );
existMark = (sal_uInt8*) (*func)();
- func = (sal_IntPtr(*)()) osl_getFunctionSymbol( hModule, OUString::createFromAscii("getIndex1").pData );
+ func = (sal_IntPtr(*)()) osl_getFunctionSymbol( hModule, OUString(RTL_CONSTASCII_USTRINGPARAM("getIndex1")).pData );
index1 = (sal_Int16*) (*func)();
- func = (sal_IntPtr(*)()) osl_getFunctionSymbol( hModule, OUString::createFromAscii("getIndex2").pData );
+ func = (sal_IntPtr(*)()) osl_getFunctionSymbol( hModule, OUString(RTL_CONSTASCII_USTRINGPARAM("getIndex2")).pData );
index2 = (sal_Int32*) (*func)();
- func = (sal_IntPtr(*)()) osl_getFunctionSymbol( hModule, OUString::createFromAscii("getLenArray").pData );
+ func = (sal_IntPtr(*)()) osl_getFunctionSymbol( hModule, OUString(RTL_CONSTASCII_USTRINGPARAM("getLenArray")).pData );
lenArray = (sal_Int32*) (*func)();
- func = (sal_IntPtr(*)()) osl_getFunctionSymbol( hModule, OUString::createFromAscii("getDataArea").pData );
+ func = (sal_IntPtr(*)()) osl_getFunctionSymbol( hModule, OUString(RTL_CONSTASCII_USTRINGPARAM("getDataArea")).pData );
dataArea = (sal_Unicode*) (*func)();
}
else
diff --git a/i18npool/source/calendar/calendarImpl.cxx b/i18npool/source/calendar/calendarImpl.cxx
index 0999b6e..714fdcb 100644
--- a/i18npool/source/calendar/calendarImpl.cxx
+++ b/i18npool/source/calendar/calendarImpl.cxx
@@ -82,7 +82,7 @@ CalendarImpl::loadCalendar(const OUString& uniqueID, const Locale& rLocale ) thr
if (i >= sal::static_int_cast<sal_Int32>(lookupTable.size())) {
Reference < XInterface > xI = xMSF->createInstance(
- OUString::createFromAscii("com.sun.star.i18n.Calendar_") + uniqueID);
+ OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.i18n.Calendar_")) + uniqueID);
if ( ! xI.is() ) {
// check if the calendar is defined in localedata, load gregorian calendar service.
@@ -90,7 +90,7 @@ CalendarImpl::loadCalendar(const OUString& uniqueID, const Locale& rLocale ) thr
for (i = 0; i < xC.getLength(); i++) {
if (uniqueID == xC[i].Name) {
xI = xMSF->createInstance(
- OUString::createFromAscii("com.sun.star.i18n.Calendar_gregorian"));
+ OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.i18n.Calendar_gregorian")));
break;
}
}
@@ -304,7 +304,7 @@ CalendarImpl::getDisplayString( sal_Int32 nCalendarDisplayCode, sal_Int16 nNativ
OUString SAL_CALL
CalendarImpl::getImplementationName(void) throw( RuntimeException )
{
- return OUString::createFromAscii("com.sun.star.i18n.CalendarImpl");
+ return OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.i18n.CalendarImpl"));
}
const sal_Char cCalendar[] = "com.sun.star.i18n.LocaleCalendar";
diff --git a/i18npool/source/calendar/calendar_gregorian.cxx b/i18npool/source/calendar/calendar_gregorian.cxx
index abdda18..ef6faaa 100644
--- a/i18npool/source/calendar/calendar_gregorian.cxx
+++ b/i18npool/source/calendar/calendar_gregorian.cxx
@@ -190,7 +190,7 @@ Calendar_hanja::getDisplayName( sal_Int16 displayIndex, sal_Int16 idx, sal_Int16
if ( displayIndex == CalendarDisplayIndex::AM_PM ) {
// Am/Pm string for Korean Hanja calendar will refer to Japanese locale
com::sun::star::lang::Locale jaLocale =
- com::sun::star::lang::Locale(OUString::createFromAscii("ja"), OUString(), OUString());
+ com::sun::star::lang::Locale(OUString(RTL_CONSTASCII_USTRINGPARAM("ja")), OUString(), OUString());
if (idx == 0) return LocaleData().getLocaleItem(jaLocale).timeAM;
else if (idx == 1) return LocaleData().getLocaleItem(jaLocale).timePM;
else throw ERROR;
@@ -204,7 +204,7 @@ Calendar_hanja::loadCalendar( const OUString& /*uniqueID*/, const com::sun::star
{
// Since this class could be called by service name 'hanja_yoil', we have to
// rename uniqueID to get right calendar defined in locale data.
- Calendar_gregorian::loadCalendar(OUString::createFromAscii("hanja"), rLocale);
+ Calendar_gregorian::loadCalendar(OUString(RTL_CONSTASCII_USTRINGPARAM("hanja")), rLocale);
}
static Era gengou_eraArray[] = {
diff --git a/i18npool/source/characterclassification/characterclassificationImpl.cxx b/i18npool/source/characterclassification/characterclassificationImpl.cxx
index 0cf35e3..e76240b 100644
--- a/i18npool/source/characterclassification/characterclassificationImpl.cxx
+++ b/i18npool/source/characterclassification/characterclassificationImpl.cxx
@@ -41,7 +41,7 @@ namespace com { namespace sun { namespace star { namespace i18n {
CharacterClassificationImpl::CharacterClassificationImpl(
const Reference < lang::XMultiServiceFactory >& rxMSF ) : xMSF( rxMSF )
{
- if (createLocaleSpecificCharacterClassification(OUString::createFromAscii("Unicode"), Locale()))
+ if (createLocaleSpecificCharacterClassification(OUString(RTL_CONSTASCII_USTRINGPARAM("Unicode")), Locale()))
xUCI = cachedItem->xCI;
}
@@ -150,7 +150,7 @@ sal_Bool SAL_CALL CharacterClassificationImpl::createLocaleSpecificCharacterClas
}
Reference < XInterface > xI = xMSF->createInstance(
- OUString::createFromAscii("com.sun.star.i18n.CharacterClassification_") + serviceName);
+ OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.i18n.CharacterClassification_")) + serviceName);
Reference < XCharacterClassification > xCI;
if ( xI.is() ) {
@@ -178,7 +178,7 @@ CharacterClassificationImpl::getLocaleSpecificCharacterClassification(const Loca
}
static sal_Unicode under = (sal_Unicode)'_';
- static OUString tw(OUString::createFromAscii("TW"));
+ static OUString tw(RTL_CONSTASCII_USTRINGPARAM("TW"));
sal_Int32 l = rLocale.Language.getLength();
sal_Int32 c = rLocale.Country.getLength();
sal_Int32 v = rLocale.Variant.getLength();
@@ -203,7 +203,7 @@ CharacterClassificationImpl::getLocaleSpecificCharacterClassification(const Loca
createLocaleSpecificCharacterClassification(rLocale.Language, rLocale))) {
return cachedItem->xCI;
} else if (xUCI.is()) {
- lookupTable.push_back( cachedItem = new lookupTableItem(rLocale, OUString::createFromAscii("Unicode"), xUCI) );
+ lookupTable.push_back( cachedItem = new lookupTableItem(rLocale, OUString(RTL_CONSTASCII_USTRINGPARAM("Unicode")), xUCI) );
return cachedItem->xCI;
}
}
diff --git a/i18npool/source/collator/chaptercollator.cxx b/i18npool/source/collator/chaptercollator.cxx
index 842d81f..db5edcf 100644
--- a/i18npool/source/collator/chaptercollator.cxx
+++ b/i18npool/source/collator/chaptercollator.cxx
@@ -45,7 +45,7 @@ ChapterCollator::ChapterCollator( const Reference < XMultiServiceFactory >& rxMS
{
if ( rxMSF.is()) {
Reference < XInterface > xI =
- rxMSF->createInstance( OUString::createFromAscii("com.sun.star.i18n.CharacterClassification"));
+ rxMSF->createInstance( OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.i18n.CharacterClassification")));
if ( xI.is() )
xI->queryInterface(::getCppuType((const Reference< XCharacterClassification>*)0)) >>= cclass;
}
diff --git a/i18npool/source/collator/collatorImpl.cxx b/i18npool/source/collator/collatorImpl.cxx
index c315d89..17dab87 100644
--- a/i18npool/source/collator/collatorImpl.cxx
+++ b/i18npool/source/collator/collatorImpl.cxx
@@ -44,7 +44,7 @@ CollatorImpl::CollatorImpl( const Reference < XMultiServiceFactory >& rxMSF ) :
{
if ( rxMSF.is()) {
Reference < XInterface > xI =
- xMSF->createInstance( OUString::createFromAscii("com.sun.star.i18n.LocaleData"));
+ xMSF->createInstance( OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.i18n.LocaleData")));
if ( xI.is() )
xI->queryInterface(::getCppuType((const Reference< XLocaleData>*)0)) >>= localedata;
}
@@ -168,7 +168,7 @@ CollatorImpl::createCollator(const lang::Locale& rLocale, const OUString& servic
}
if (xMSF.is()) {
Reference < XInterface > xI =
- xMSF->createInstance(OUString::createFromAscii("com.sun.star.i18n.Collator_") + serviceName);
+ xMSF->createInstance(OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.i18n.Collator_")) + serviceName);
if (xI.is()) {
Reference < XCollator > xC;
@@ -195,8 +195,8 @@ CollatorImpl::loadCachedCollator(const lang::Locale& rLocale, const OUString& rS
}
static sal_Unicode under = (sal_Unicode) '_';
- static OUString tw(OUString::createFromAscii("TW"));
- static OUString unicode(OUString::createFromAscii("Unicode"));
+ static OUString tw(RTL_CONSTASCII_USTRINGPARAM("TW"));
+ static OUString unicode(RTL_CONSTASCII_USTRINGPARAM("Unicode"));
sal_Int32 l = rLocale.Language.getLength();
sal_Int32 c = rLocale.Country.getLength();
diff --git a/i18npool/source/collator/collator_unicode.cxx b/i18npool/source/collator/collator_unicode.cxx
index 6d0ed67..084e4ce 100644
--- a/i18npool/source/collator/collator_unicode.cxx
+++ b/i18npool/source/collator/collator_unicode.cxx
@@ -97,9 +97,9 @@ Collator_Unicode::loadCollatorAlgorithm(const OUString& rAlgorithm, const lang::
aBuf.appendAscii("get_").append(rLocale.Language).appendAscii("_");
if (rLocale.Language.equalsAscii("zh")) {
OUString func_base = aBuf.makeStringAndClear();
- if (OUString::createFromAscii("TW HK MO").indexOf(rLocale.Country) >= 0)
+ if (OUString(RTL_CONSTASCII_USTRINGPARAM("TW HK MO")).indexOf(rLocale.Country) >= 0)
func=(const sal_uInt8* (*)()) osl_getFunctionSymbol(hModule,
- (func_base + OUString::createFromAscii("TW_") + rAlgorithm).pData);
+ (func_base + OUString(RTL_CONSTASCII_USTRINGPARAM("TW_")) + rAlgorithm).pData);
if (!func)
func=(const sal_uInt8* (*)()) osl_getFunctionSymbol(hModule, (func_base + rAlgorithm).pData);
} else {
diff --git a/i18npool/source/defaultnumberingprovider/defaultnumberingprovider.cxx b/i18npool/source/defaultnumberingprovider/defaultnumberingprovider.cxx
index fe49cd2..2c4cf7b 100644
--- a/i18npool/source/defaultnumberingprovider/defaultnumberingprovider.cxx
+++ b/i18npool/source/defaultnumberingprovider/defaultnumberingprovider.cxx
@@ -420,10 +420,10 @@ DefaultNumberingProvider::makeNumberingString( const Sequence<beans::PropertyVal
result += OUString::valueOf( number );
break;
case NUMBER_NONE:
- return OUString::createFromAscii(""); // ignore prefix and suffix
+ return OUString(RTL_CONSTASCII_USTRINGPARAM("")); // ignore prefix and suffix
case CHAR_SPECIAL:
// apparently, we're supposed to return an empty string in this case...
- return OUString::createFromAscii(""); // ignore prefix and suffix
+ return OUString(RTL_CONSTASCII_USTRINGPARAM("")); // ignore prefix and suffix
case PAGE_DESCRIPTOR:
case BITMAP:
OSL_ASSERT(0);
@@ -459,25 +459,25 @@ DefaultNumberingProvider::makeNumberingString( const Sequence<beans::PropertyVal
break;
case NUMBER_LOWER_ZH:
natNum = NativeNumberMode::NATNUM7;
- locale.Language = OUString::createFromAscii("zh");
+ locale.Language = OUString(RTL_CONSTASCII_USTRINGPARAM("zh"));
break;
case NUMBER_UPPER_ZH_TW:
- locale.Country = OUString::createFromAscii("TW");
+ locale.Country = OUString(RTL_CONSTASCII_USTRINGPARAM("TW"));
case NUMBER_UPPER_ZH:
natNum = NativeNumberMode::NATNUM8;
- locale.Language = OUString::createFromAscii("zh");
+ locale.Language = OUString(RTL_CONSTASCII_USTRINGPARAM("zh"));
break;
case NUMBER_TRADITIONAL_JA:
natNum = NativeNumberMode::NATNUM8;
- locale.Language = OUString::createFromAscii("ja");
+ locale.Language = OUString(RTL_CONSTASCII_USTRINGPARAM("ja"));
break;
case NUMBER_UPPER_KO:
natNum = NativeNumberMode::NATNUM8;
- locale.Language = OUString::createFromAscii("ko");
+ locale.Language = OUString(RTL_CONSTASCII_USTRINGPARAM("ko"));
break;
case NUMBER_HANGUL_KO:
natNum = NativeNumberMode::NATNUM11;
- locale.Language = OUString::createFromAscii("ko");
+ locale.Language = OUString(RTL_CONSTASCII_USTRINGPARAM("ko"));
break;
case CIRCLE_NUMBER:
@@ -721,17 +721,17 @@ OUString DefaultNumberingProvider::makeNumberingIdentifier(sal_Int16 index)
// return OUString::createFromAscii(aSupportedTypes[index].cSymbol);
else {
OUString result;
- Locale aLocale(OUString::createFromAscii("en"), OUString(), OUString());
+ Locale aLocale(OUString(RTL_CONSTASCII_USTRINGPARAM("en")), OUString(), OUString());
Sequence<beans::PropertyValue> aProperties(2);
- aProperties[0].Name = OUString::createFromAscii("NumberingType");
+ aProperties[0].Name = OUString(RTL_CONSTASCII_USTRINGPARAM("NumberingType"));
aProperties[0].Value <<= aSupportedTypes[index].nType;
- aProperties[1].Name = OUString::createFromAscii("Value");
+ aProperties[1].Name = OUString(RTL_CONSTASCII_USTRINGPARAM("Value"));
for (sal_Int32 j = 1; j <= 3; j++) {
aProperties[1].Value <<= j;
result += makeNumberingString( aProperties, aLocale );
- result += OUString::createFromAscii(", ");
+ result += OUString(RTL_CONSTASCII_USTRINGPARAM(", "));
}
- result += OUString::createFromAscii("...");
+ result += OUString(RTL_CONSTASCII_USTRINGPARAM("..."));
return result;
}
}
@@ -742,7 +742,7 @@ DefaultNumberingProvider::isScriptFlagEnabled(const OUString& aName) throw(Runti
if (! xHierarchicalNameAccess.is()) {
Reference< XInterface > xInterface;
- xInterface = xSMgr->createInstance(OUString::createFromAscii("com.sun.star.configuration.ConfigurationProvider"));
+ xInterface = xSMgr->createInstance(OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.configuration.ConfigurationProvider")));
Reference< XMultiServiceFactory > xConfigProvider =
Reference< XMultiServiceFactory >(xInterface, UNO_QUERY );
@@ -751,12 +751,12 @@ DefaultNumberingProvider::isScriptFlagEnabled(const OUString& aName) throw(Runti
Sequence< Any > aArgs(1);
beans::PropertyValue aPath;
- aPath.Name = OUString::createFromAscii("nodepath");
- aPath.Value <<= OUString::createFromAscii("/org.openoffice.Office.Common/I18N"),
+ aPath.Name = OUString(RTL_CONSTASCII_USTRINGPARAM("nodepath"));
+ aPath.Value <<= OUString(RTL_CONSTASCII_USTRINGPARAM("/org.openoffice.Office.Common/I18N")),
aArgs[0] <<= aPath;
xInterface = xConfigProvider->createInstanceWithArguments(
- OUString::createFromAscii("com.sun.star.configuration.ConfigurationAccess"), aArgs);
+ OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.configuration.ConfigurationAccess")), aArgs);
xHierarchicalNameAccess.set(xInterface, UNO_QUERY);
@@ -779,8 +779,8 @@ Sequence< sal_Int16 > DefaultNumberingProvider::getSupportedNumberingTypes( )
Sequence< sal_Int16 > aRet(nSupported_NumberingTypes );
sal_Int16* pArray = aRet.getArray();
- sal_Bool cjkEnabled = isScriptFlagEnabled(OUString::createFromAscii("CJK/CJKFont"));
- sal_Bool ctlEnabled = isScriptFlagEnabled(OUString::createFromAscii("CTL/CTLFont"));
+ sal_Bool cjkEnabled = isScriptFlagEnabled(OUString(RTL_CONSTASCII_USTRINGPARAM("CJK/CJKFont")));
+ sal_Bool ctlEnabled = isScriptFlagEnabled(OUString(RTL_CONSTASCII_USTRINGPARAM("CTL/CTLFont")));
for(sal_Int16 i = 0; i < nSupported_NumberingTypes; i++) {
if ( (aSupportedTypes[i].langOption & LANG_ALL) ||
diff --git a/i18npool/source/indexentry/indexentrysupplier.cxx b/i18npool/source/indexentry/indexentrysupplier.cxx
index 603a4a6..5aa7001 100644
--- a/i18npool/source/indexentry/indexentrysupplier.cxx
+++ b/i18npool/source/indexentry/indexentrysupplier.cxx
@@ -113,7 +113,7 @@ OUString SAL_CALL IndexEntrySupplier::getIndexCharacter( const OUString& rIndexE
sal_Bool SAL_CALL IndexEntrySupplier::createLocaleSpecificIndexEntrySupplier(const OUString& name) throw( RuntimeException )
{
Reference < XInterface > xI = xMSF->createInstance(
- OUString::createFromAscii("com.sun.star.i18n.IndexEntrySupplier_") + name);
+ OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.i18n.IndexEntrySupplier_")) + name);
if ( xI.is() ) {
xI->queryInterface( ::getCppuType((const Reference< com::sun::star::i18n::XExtendedIndexEntrySupplier>*)0) ) >>= xIES;
@@ -168,7 +168,7 @@ IndexEntrySupplier::getLocaleSpecificIndexEntrySupplier(const Locale& rLocale, c
// load service with name <base>_<algorithm>
(a > 0 && createLocaleSpecificIndexEntrySupplier(aSortAlgorithm)) ||
// load default service with name <base>_Unicode
- createLocaleSpecificIndexEntrySupplier(OUString::createFromAscii("Unicode"))) {
+ createLocaleSpecificIndexEntrySupplier(OUString(RTL_CONSTASCII_USTRINGPARAM("Unicode")))) {
return xIES;
}
}
diff --git a/i18npool/source/indexentry/indexentrysupplier_asian.cxx b/i18npool/source/indexentry/indexentrysupplier_asian.cxx
index 769ed69..9c219a8 100644
--- a/i18npool/source/indexentry/indexentrysupplier_asian.cxx
+++ b/i18npool/source/indexentry/indexentrysupplier_asian.cxx
@@ -66,10 +66,10 @@ IndexEntrySupplier_asian::getIndexCharacter( const OUString& rIndexEntry,
sal_Int32 i=0;
sal_uInt32 ch = rIndexEntry.iterateCodePoints(&i, 0);
if (hModule) {
- OUString get=OUString::createFromAscii("get_indexdata_");
+ OUString get(RTL_CONSTASCII_USTRINGPARAM("get_indexdata_"));
sal_uInt16** (*func)(sal_Int16*)=NULL;
- if (rLocale.Language.equalsAscii("zh") && OUString::createFromAscii("TW HK MO").indexOf(rLocale.Country) >= 0)
- func=(sal_uInt16** (*)(sal_Int16*))osl_getFunctionSymbol(hModule, (get+rLocale.Language+OUString::createFromAscii("_TW_")+rAlgorithm).pData);
+ if (rLocale.Language.equalsAscii("zh") && OUString(RTL_CONSTASCII_USTRINGPARAM("TW HK MO")).indexOf(rLocale.Country) >= 0)
+ func=(sal_uInt16** (*)(sal_Int16*))osl_getFunctionSymbol(hModule, (get+rLocale.Language+OUString(RTL_CONSTASCII_USTRINGPARAM("_TW_"))+rAlgorithm).pData);
if (!func)
func=(sal_uInt16** (*)(sal_Int16*))osl_getFunctionSymbol(hModule, (get+rLocale.Language+OUString('_')+rAlgorithm).pData);
if (func) {
@@ -121,7 +121,7 @@ IndexEntrySupplier_asian::getPhoneticCandidate( const OUString& rIndexEntry,
sal_uInt16 **(*func)(sal_Int16*)=NULL;
const sal_Char *func_name=NULL;
if (rLocale.Language.equalsAscii("zh"))
- func_name=(OUString::createFromAscii("TW HK MO").indexOf(rLocale.Country) >= 0) ? "get_zh_zhuyin" : "get_zh_pinyin";
+ func_name=(OUString(RTL_CONSTASCII_USTRINGPARAM("TW HK MO")).indexOf(rLocale.Country) >= 0) ? "get_zh_zhuyin" : "get_zh_pinyin";
else if (rLocale.Language.equalsAscii("ko"))
func_name="get_ko_phonetic";
if (func_name)
diff --git a/i18npool/source/indexentry/indexentrysupplier_default.cxx b/i18npool/source/indexentry/indexentrysupplier_default.cxx
index e6f8695..174ede7 100644
--- a/i18npool/source/indexentry/indexentrysupplier_default.cxx
+++ b/i18npool/source/indexentry/indexentrysupplier_default.cxx
@@ -170,7 +170,7 @@ OUString Index::getIndexDescription(const OUString& rIndexEntry)
return OUString(&indexChar, 1);
}
-#define LOCALE_EN lang::Locale(OUString::createFromAscii("en"), OUString(), OUString())
+#define LOCALE_EN lang::Locale(OUString(RTL_CONSTASCII_USTRINGPARAM("en")), OUString(), OUString())
void Index::makeIndexKeys(const lang::Locale &rLocale, const OUString &algorithm) throw (RuntimeException)
{
diff --git a/i18npool/source/inputchecker/inputsequencechecker.cxx b/i18npool/source/inputchecker/inputsequencechecker.cxx
index ccc4eeb..f9ffdb1 100644
--- a/i18npool/source/inputchecker/inputsequencechecker.cxx
+++ b/i18npool/source/inputchecker/inputsequencechecker.cxx
@@ -129,7 +129,7 @@ InputSequenceCheckerImpl::getInputSequenceChecker(sal_Char* rLanguage) throw (Ru
}
Reference < uno::XInterface > xI = xMSF->createInstance(
- OUString::createFromAscii("com.sun.star.i18n.InputSequenceChecker_") +
+ OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.i18n.InputSequenceChecker_")) +
OUString::createFromAscii(rLanguage));
if ( xI.is() ) {
diff --git a/i18npool/source/localedata/LocaleNode.cxx b/i18npool/source/localedata/LocaleNode.cxx
index 083c31e..cfec35f 100644
--- a/i18npool/source/localedata/LocaleNode.cxx
+++ b/i18npool/source/localedata/LocaleNode.cxx
@@ -1111,7 +1111,7 @@ void LCCalendarNode::generateCode (const OFileWriter &of) const
}
}
if (ref_name.getLength() > 0 && daysNode == NULL) {
- of.writeParameter("dayRef", OUString::createFromAscii("ref"), i);
+ of.writeParameter("dayRef", OUString(RTL_CONSTASCII_USTRINGPARAM("ref")), i);
of.writeParameter("dayRefName", ref_name, i);
nbOfDays[i] = 0;
} else {
@@ -1143,7 +1143,7 @@ void LCCalendarNode::generateCode (const OFileWriter &of) const
}
}
if (ref_name.getLength() > 0 && monthsNode == NULL) {
- of.writeParameter("monthRef", OUString::createFromAscii("ref"), i);
+ of.writeParameter("monthRef", OUString(RTL_CONSTASCII_USTRINGPARAM("ref")), i);
of.writeParameter("monthRefName", ref_name, i);
nbOfMonths[i] = 0;
} else {
@@ -1175,7 +1175,7 @@ void LCCalendarNode::generateCode (const OFileWriter &of) const
}
}
if (ref_name.getLength() > 0 && erasNode == NULL) {
- of.writeParameter("eraRef", OUString::createFromAscii("ref"), i);
+ of.writeParameter("eraRef", OUString(RTL_CONSTASCII_USTRINGPARAM("ref")), i);
of.writeParameter("eraRefName", ref_name, i);
nbOfEras[i] = 0;
} else {
diff --git a/i18npool/source/localedata/localedata.cxx b/i18npool/source/localedata/localedata.cxx
index 42ebf76..6ea8ba7 100644
--- a/i18npool/source/localedata/localedata.cxx
+++ b/i18npool/source/localedata/localedata.cxx
@@ -484,7 +484,7 @@ Sequence< CalendarItem > &LocaleData::getCalendarItemByName(const OUString& name
// Refered locale does not found, return name for en_US locale.
if (index == cals.getLength()) {
cals = getAllCalendars(
- Locale(OUString::createFromAscii("en"), OUString::createFromAscii("US"), OUString()));
+ Locale(OUString(RTL_CONSTASCII_USTRINGPARAM("en")), OUString(RTL_CONSTASCII_USTRINGPARAM("US")), OUString()));
if (cals.getLength() > 0)
ref_cal = cals[0];
else
@@ -876,7 +876,7 @@ OUString SAL_CALL
LocaleData::getIndexKeysByAlgorithm( const Locale& rLocale, const OUString& algorithm ) throw(RuntimeException)
{
sal_Unicode **indexArray = getIndexArrayForAlgorithm(rLocale, algorithm);
- return indexArray ? OUString::createFromAscii("0-9")+OUString(indexArray[2]) : OUString();
+ return indexArray ? OUString(RTL_CONSTASCII_USTRINGPARAM("0-9"))+OUString(indexArray[2]) : OUString();
}
OUString SAL_CALL
@@ -1296,8 +1296,8 @@ oslGenericFunction SAL_CALL LocaleData::getFunctionSymbol( const Locale& rLocale
}
oslGenericFunction pSymbol = 0;
- static OUString tw(OUString::createFromAscii("TW"));
- static OUString en_US(OUString::createFromAscii("en_US"));
+ static OUString tw(RTL_CONSTASCII_USTRINGPARAM("TW"));
+ static OUString en_US(RTL_CONSTASCII_USTRINGPARAM("en_US"));
sal_Int32 l = rLocale.Language.getLength();
sal_Int32 c = rLocale.Country.getLength();
diff --git a/i18npool/source/localedata/saxparser.cxx b/i18npool/source/localedata/saxparser.cxx
index bd7b5e5..04279fb 100644
--- a/i18npool/source/localedata/saxparser.cxx
+++ b/i18npool/source/localedata/saxparser.cxx
@@ -354,7 +354,7 @@ SAL_IMPLEMENT_MAIN_WITH_ARGS(argc, argv)
{
// Create registration service
Reference < XInterface > x = xSMgr->createInstance(
- OUString::createFromAscii( "com.sun.star.registry.ImplementationRegistration" ) );
+ OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.registry.ImplementationRegistration")) );
xReg = Reference< XImplementationRegistration > ( x , UNO_QUERY );
}
catch( Exception & ) {
@@ -369,7 +369,7 @@ SAL_IMPLEMENT_MAIN_WITH_ARGS(argc, argv)
OUString aDllName =
OUString::createFromAscii( "sax.uno" SAL_DLLEXTENSION );
xReg->registerImplementation(
- OUString::createFromAscii( "com.sun.star.loader.SharedLibrary" ),
+ OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.loader.SharedLibrary")),
aDllName,
Reference< XSimpleRegistry > () );
}
@@ -386,7 +386,7 @@ SAL_IMPLEMENT_MAIN_WITH_ARGS(argc, argv)
// read xml from a file and count elements
//--------------------------------
Reference< XInterface > x = xSMgr->createInstance(
- OUString::createFromAscii( "com.sun.star.xml.sax.Parser" ) );
+ OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.xml.sax.Parser")) );
int nError = 0;
if( x.is() )
{
diff --git a/i18npool/source/numberformatcode/numberformatcode.cxx b/i18npool/source/numberformatcode/numberformatcode.cxx
index a868bc0..051e204 100644
--- a/i18npool/source/numberformatcode/numberformatcode.cxx
+++ b/i18npool/source/numberformatcode/numberformatcode.cxx
@@ -283,7 +283,7 @@ NumberFormatCodeMapper::createLocaleDataObject() {
NumberFormatCodeMapper::getImplementationName(void)
throw( ::com::sun::star::uno::RuntimeException )
{
- return ::rtl::OUString::createFromAscii("com.sun.star.i18n.NumberFormatCodeMapper");
+ return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.i18n.NumberFormatCodeMapper"));
}
const sal_Char cNumFormat[] = "com.sun.star.i18n.NumberFormatMapper";
diff --git a/i18npool/source/ordinalsuffix/ordinalsuffix.cxx b/i18npool/source/ordinalsuffix/ordinalsuffix.cxx
index 1d49446..224ea8e 100644
--- a/i18npool/source/ordinalsuffix/ordinalsuffix.cxx
+++ b/i18npool/source/ordinalsuffix/ordinalsuffix.cxx
@@ -59,22 +59,22 @@ static OUString getOrdinalSuffixEn( sal_Int32 nNumber )
switch( labs( nNumber ) % 100 )
{
case 11: case 12: case 13:
- retValue = OUString::createFromAscii( "th" );
+ retValue = OUString(RTL_CONSTASCII_USTRINGPARAM("th"));
break;
default:
switch( nNumber % 10 )
{
case 1:
- retValue = OUString::createFromAscii( "st" );
+ retValue = OUString(RTL_CONSTASCII_USTRINGPARAM("st"));
break;
case 2:
- retValue = OUString::createFromAscii( "nd" );
+ retValue = OUString(RTL_CONSTASCII_USTRINGPARAM("nd"));
break;
case 3:
- retValue = OUString::createFromAscii( "rd" );
+ retValue = OUString(RTL_CONSTASCII_USTRINGPARAM("rd"));
break;
default:
- retValue = OUString::createFromAscii( "th" );
+ retValue = OUString(RTL_CONSTASCII_USTRINGPARAM("th"));
break;
}
break;
diff --git a/i18npool/source/registerservices/registerservices.cxx b/i18npool/source/registerservices/registerservices.cxx
index 3be4a94..615e724 100644
--- a/i18npool/source/registerservices/registerservices.cxx
+++ b/i18npool/source/registerservices/registerservices.cxx
@@ -596,7 +596,7 @@ sal_Bool SAL_CALL component_writeInfo( void* /*_pServiceManager*/, void* _pRegis
xNewKey = pRegistryKey->createKey(
::rtl::OUString::createFromAscii( pArr->pImplementationNm ) );
xNewKey = xNewKey->createKey(
- ::rtl::OUString::createFromAscii( "/UNO/SERVICES" ) );
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("/UNO/SERVICES")) );
xNewKey->createKey(
::rtl::OUString::createFromAscii( pArr->pServiceNm ) );
}
diff --git a/i18npool/source/search/textsearch.cxx b/i18npool/source/search/textsearch.cxx
index bd65bea..ce51c19 100644
--- a/i18npool/source/search/textsearch.cxx
+++ b/i18npool/source/search/textsearch.cxx
@@ -153,7 +153,7 @@ void TextSearch::setOptions( const SearchOptions& rOptions ) throw( RuntimeExcep
if ( !xBreak.is() )
{
Reference < XInterface > xI = xMSF->createInstance(
- OUString::createFromAscii( "com.sun.star.i18n.BreakIterator"));
+ OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.i18n.BreakIterator")));
if( xI.is() )
xI->queryInterface( ::getCppuType(
(const Reference< XBreakIterator >*)0))
@@ -413,7 +413,7 @@ bool TextSearch::IsDelimiter( const OUString& rStr, sal_Int32 nPos ) const
if ( !xCharClass.is() )
{
Reference < XInterface > xI = xMSF->createInstance(
- OUString::createFromAscii( "com.sun.star.i18n.CharacterClassification"));
+ OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.i18n.CharacterClassification")));
if( xI.is() )
xI->queryInterface( ::getCppuType(
(const Reference< XCharacterClassification >*)0))
@@ -1001,7 +1001,7 @@ sal_Bool SAL_CALL component_writeInfo(
xNewKey = pRegistryKey->createKey( getImplementationName_Static() );
xNewKey = xNewKey->createKey(
- ::rtl::OUString::createFromAscii( "/UNO/SERVICES" ) );
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("/UNO/SERVICES")) );
xNewKey->createKey( getServiceName_Static() );
}
return sal_True;
diff --git a/i18npool/source/textconversion/textconversionImpl.cxx b/i18npool/source/textconversion/textconversionImpl.cxx
index 3a7a1eb..a8aba23 100644
--- a/i18npool/source/textconversion/textconversionImpl.cxx
+++ b/i18npool/source/textconversion/textconversionImpl.cxx
@@ -99,17 +99,17 @@ TextConversionImpl::getLocaleSpecificTextConversion(const Locale& rLocale) throw
Reference < XInterface > xI;
xI = xMSF->createInstance(
- OUString::createFromAscii("com.sun.star.i18n.TextConversion_") + aLocale.Language);
+ OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.i18n.TextConversion_")) + aLocale.Language);
if ( ! xI.is() )
xI = xMSF->createInstance(
- OUString::createFromAscii("com.sun.star.i18n.TextConversion_") + aLocale.Language +
- OUString::createFromAscii("_") + aLocale.Country);
+ OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.i18n.TextConversion_")) + aLocale.Language +
+ OUString(RTL_CONSTASCII_USTRINGPARAM("_")) + aLocale.Country);
if ( ! xI.is() )
xI = xMSF->createInstance(
- OUString::createFromAscii("com.sun.star.i18n.TextConversion_") + aLocale.Language +
- OUString::createFromAscii("_") + aLocale.Country +
- OUString::createFromAscii("_") + aLocale.Variant);
+ OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.i18n.TextConversion_")) + aLocale.Language +
+ OUString(RTL_CONSTASCII_USTRINGPARAM("_")) + aLocale.Country +
+ OUString(RTL_CONSTASCII_USTRINGPARAM("_")) + aLocale.Variant);
if (xI.is())
xI->queryInterface( getCppuType((const Reference< XTextConversion>*)0) ) >>= xTC;
diff --git a/i18npool/source/textconversion/textconversion_ko.cxx b/i18npool/source/textconversion/textconversion_ko.cxx
index a3dadea..8255f40 100644
--- a/i18npool/source/textconversion/textconversion_ko.cxx
+++ b/i18npool/source/textconversion/textconversion_ko.cxx
@@ -55,13 +55,13 @@ TextConversion_ko::TextConversion_ko( const Reference < XMultiServiceFactory >&
Reference < XInterface > xI;
xI = xMSF->createInstance(
- OUString::createFromAscii("com.sun.star.i18n.ConversionDictionary_ko"));
+ OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.i18n.ConversionDictionary_ko")));
if ( xI.is() )
xI->queryInterface( getCppuType((const Reference< XConversionDictionary>*)0) ) >>= xCD;
xI = xMSF->createInstance(
- OUString::createFromAscii( "com.sun.star.linguistic2.ConversionDictionaryList" ));
+ OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.linguistic2.ConversionDictionaryList")));
if ( xI.is() )
xI->queryInterface( getCppuType((const Reference< XConversionDictionaryList>*)0) ) >>= xCDL;
@@ -70,8 +70,8 @@ TextConversion_ko::TextConversion_ko( const Reference < XMultiServiceFactory >&
// get maximum length of word in dictionary
if (xCDL.is()) {
- Locale loc(OUString::createFromAscii("ko"),
- OUString::createFromAscii("KR"),
+ Locale loc(OUString(RTL_CONSTASCII_USTRINGPARAM("ko")),
+ OUString(RTL_CONSTASCII_USTRINGPARAM("KR")),
OUString());
maxLeftLength = xCDL->queryMaxCharCount(loc,
ConversionDictionaryType::HANGUL_HANJA,
diff --git a/i18npool/source/textconversion/textconversion_zh.cxx b/i18npool/source/textconversion/textconversion_zh.cxx
index 03c27c4..c88d42e 100644
--- a/i18npool/source/textconversion/textconversion_zh.cxx
+++ b/i18npool/source/textconversion/textconversion_zh.cxx
@@ -49,7 +49,7 @@ TextConversion_zh::TextConversion_zh( const Reference < XMultiServiceFactory >&
{
Reference < XInterface > xI;
xI = xMSF->createInstance(
- OUString::createFromAscii( "com.sun.star.linguistic2.ConversionDictionaryList" ));
+ OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.linguistic2.ConversionDictionaryList")));
if ( xI.is() )
xI->queryInterface( getCppuType((const Reference< XConversionDictionaryList>*)0) ) >>= xCDL;
diff --git a/i18npool/source/transliteration/transliterationImpl.cxx b/i18npool/source/transliteration/transliterationImpl.cxx
index 3e14566..ce24756 100644
--- a/i18npool/source/transliteration/transliterationImpl.cxx
+++ b/i18npool/source/transliteration/transliterationImpl.cxx
@@ -158,7 +158,7 @@ TransliterationImpl::TransliterationImpl(const Reference <XMultiServiceFactory>&
if ( xMSF.is() )
{
Reference < XInterface > xI=
- xMSF->createInstance(OUString::createFromAscii("com.sun.star.i18n.LocaleData"));
+ xMSF->createInstance(OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.i18n.LocaleData")));
if ( xI.is() ) {
Any x = xI->queryInterface( ::getCppuType( (const uno::Reference< i18n::XLocaleData >*)0) );
x >>= localedata;
@@ -180,7 +180,7 @@ TransliterationImpl::getName() throw(RuntimeException)
if (numCascade == 1 && bodyCascade[0].is())
return bodyCascade[0]->getName();
if (numCascade < 1)
- return ( OUString::createFromAscii("Not Loaded"));
+ return ( OUString(RTL_CONSTASCII_USTRINGPARAM("Not Loaded")));
throw ERROR;
}
More information about the Libreoffice-commits
mailing list