summaryrefslogtreecommitdiff
path: root/i18npool/source/characterclassification
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2012-11-05 15:19:49 +0200
committerStephan Bergmann <sbergman@redhat.com>2012-11-27 18:18:07 +0100
commit9df0baaf0b2d0dc22b88d13848014b402937aac6 (patch)
treea12df367d83caa5e52419b00e325dafdb6625e02 /i18npool/source/characterclassification
parentc2bbc9797c2fef9078c11460100996972bebd971 (diff)
fdo#46808, convert i18n::BreakIterator impl to XComponentContext
Change-Id: I2e6800d0f5a6346fc743d5a57bab34d1e36b4ee4
Diffstat (limited to 'i18npool/source/characterclassification')
-rw-r--r--i18npool/source/characterclassification/cclass_unicode.cxx4
-rw-r--r--i18npool/source/characterclassification/cclass_unicode_parser.cxx6
2 files changed, 5 insertions, 5 deletions
diff --git a/i18npool/source/characterclassification/cclass_unicode.cxx b/i18npool/source/characterclassification/cclass_unicode.cxx
index da8529bb9bce..5e27fa50d1d6 100644
--- a/i18npool/source/characterclassification/cclass_unicode.cxx
+++ b/i18npool/source/characterclassification/cclass_unicode.cxx
@@ -35,7 +35,7 @@ namespace com { namespace sun { namespace star { namespace i18n {
// class cclass_Unicode
// ----------------------------------------------------;
-cclass_Unicode::cclass_Unicode( uno::Reference < XMultiServiceFactory > xSMgr ) : xMSF( xSMgr ),
+cclass_Unicode::cclass_Unicode( const uno::Reference < XComponentContext >& rxContext ) : m_xContext( rxContext ),
pTable( NULL ),
pStart( NULL ),
pCont( NULL ),
@@ -90,7 +90,7 @@ cclass_Unicode::toTitle( const OUString& Text, sal_Int32 nPos, sal_Int32 nCount,
trans->setMappingType(MappingTypeToTitle, rLocale);
rtl_uString* pStr = comphelper::string::rtl_uString_alloc(nCount);
sal_Unicode* out = pStr->buffer;
- BreakIteratorImpl brk(xMSF);
+ BreakIteratorImpl brk(m_xContext);
Boundary bdy = brk.getWordBoundary(Text, nPos, rLocale,
WordType::ANYWORD_IGNOREWHITESPACES, sal_True);
for (sal_Int32 i = nPos; i < nCount + nPos; i++, out++) {
diff --git a/i18npool/source/characterclassification/cclass_unicode_parser.cxx b/i18npool/source/characterclassification/cclass_unicode_parser.cxx
index c3f5ac5b72ca..3f3de5b8f002 100644
--- a/i18npool/source/characterclassification/cclass_unicode_parser.cxx
+++ b/i18npool/source/characterclassification/cclass_unicode_parser.cxx
@@ -402,7 +402,7 @@ sal_Bool cclass_Unicode::setupInternational( const Locale& rLocale )
}
if ( !mxLocaleData.is() )
{
- mxLocaleData.set( LocaleData::create(comphelper::getComponentContext(xMSF)) );
+ mxLocaleData.set( LocaleData::create(m_xContext) );
}
return bChanged;
}
@@ -1007,9 +1007,9 @@ void cclass_Unicode::parseText( ParseResult& r, const OUString& rText, sal_Int32
{
if ( !xNatNumSup.is() )
{
- if ( xMSF.is() )
+ if ( m_xContext.is() )
{
- xNatNumSup = NativeNumberSupplier::create( comphelper::getComponentContext(xMSF) );
+ xNatNumSup = NativeNumberSupplier::create( m_xContext );
}
}
OUString aTmp( pTextStart + r.LeadingWhiteSpace, r.EndPos - nPos +