Bump version to 4.3-4
[LibreOffice.git] / unotools / source / config / syslocaleoptions.cxx
blobfa25d348aac330a7c08cac92994b2dbffdc7f275
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
3 * This file is part of the LibreOffice project.
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
9 * This file incorporates work covered by the following license notice:
11 * Licensed to the Apache Software Foundation (ASF) under one or more
12 * contributor license agreements. See the NOTICE file distributed
13 * with this work for additional information regarding copyright
14 * ownership. The ASF licenses this file to you under the Apache
15 * License, Version 2.0 (the "License"); you may not use this file
16 * except in compliance with the License. You may obtain a copy of
17 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
20 #include <com/sun/star/uno/Sequence.hxx>
21 #include <rtl/ustrbuf.hxx>
22 #include <rtl/instance.hxx>
23 #include <i18nlangtag/mslangid.hxx>
24 #include <i18nlangtag/languagetag.hxx>
25 #include <tools/debug.hxx>
26 #include <unotools/syslocaleoptions.hxx>
27 #include <unotools/configmgr.hxx>
28 #include <unotools/configitem.hxx>
29 #include <com/sun/star/uno/Any.hxx>
31 #include "itemholder1.hxx"
33 #define CFG_READONLY_DEFAULT false
35 using namespace osl;
36 using namespace utl;
37 using namespace com::sun::star::uno;
38 using namespace com::sun::star::lang;
40 SvtSysLocaleOptions_Impl* SvtSysLocaleOptions::pOptions = NULL;
41 sal_Int32 SvtSysLocaleOptions::nRefCount = 0;
42 namespace
44 struct CurrencyChangeLink
45 : public rtl::Static<Link, CurrencyChangeLink> {};
48 class SvtSysLocaleOptions_Impl : public utl::ConfigItem
50 LanguageTag m_aRealLocale;
51 LanguageTag m_aRealUILocale;
52 OUString m_aLocaleString; // en-US or de-DE or empty for SYSTEM
53 OUString m_aUILocaleString; // en-US or de-DE or empty for SYSTEM
54 OUString m_aCurrencyString; // USD-en-US or EUR-de-DE
55 OUString m_aDatePatternsString; // "Y-M-D;M-D"
56 bool m_bDecimalSeparator; //use decimal separator same as locale
57 bool m_bIgnoreLanguageChange; //OS language change doesn't affect LO document language
59 bool m_bROLocale;
60 bool m_bROUILocale;
61 bool m_bROCurrency;
62 bool m_bRODatePatterns;
63 bool m_bRODecimalSeparator;
64 bool m_bROIgnoreLanguageChange;
66 static const Sequence< /* const */ OUString > GetPropertyNames();
67 void MakeRealLocale();
68 void MakeRealUILocale();
70 public:
71 SvtSysLocaleOptions_Impl();
72 virtual ~SvtSysLocaleOptions_Impl();
74 virtual void Notify( const com::sun::star::uno::Sequence< OUString >& aPropertyNames ) SAL_OVERRIDE;
75 virtual void Commit() SAL_OVERRIDE;
77 const OUString& GetLocaleString() const
78 { return m_aLocaleString; }
79 void SetLocaleString( const OUString& rStr );
81 void SetUILocaleString( const OUString& rStr );
83 const OUString& GetCurrencyString() const
84 { return m_aCurrencyString; }
85 void SetCurrencyString( const OUString& rStr );
87 const OUString& GetDatePatternsString() const
88 { return m_aDatePatternsString; }
89 void SetDatePatternsString( const OUString& rStr );
91 bool IsDecimalSeparatorAsLocale() const { return m_bDecimalSeparator;}
92 void SetDecimalSeparatorAsLocale( bool bSet);
94 bool IsIgnoreLanguageChange() const { return m_bIgnoreLanguageChange;}
95 void SetIgnoreLanguageChange( bool bSet);
97 bool IsReadOnly( SvtSysLocaleOptions::EOption eOption ) const;
98 const LanguageTag& GetRealLocale() { return m_aRealLocale; }
99 const LanguageTag& GetRealUILocale() { return m_aRealUILocale; }
102 #define ROOTNODE_SYSLOCALE OUString("Setup/L10N")
104 #define PROPERTYNAME_LOCALE OUString("ooSetupSystemLocale")
105 #define PROPERTYNAME_UILOCALE OUString("ooLocale")
106 #define PROPERTYNAME_CURRENCY OUString("ooSetupCurrency")
107 #define PROPERTYNAME_DECIMALSEPARATOR OUString("DecimalSeparatorAsLocale")
108 #define PROPERTYNAME_DATEPATTERNS OUString("DateAcceptancePatterns")
109 #define PROPERTYNAME_IGNORELANGCHANGE OUString("IgnoreLanguageChange")
111 #define PROPERTYHANDLE_LOCALE 0
112 #define PROPERTYHANDLE_UILOCALE 1
113 #define PROPERTYHANDLE_CURRENCY 2
114 #define PROPERTYHANDLE_DECIMALSEPARATOR 3
115 #define PROPERTYHANDLE_DATEPATTERNS 4
116 #define PROPERTYHANDLE_IGNORELANGCHANGE 5
118 //#define PROPERTYCOUNT 5
119 #define PROPERTYCOUNT 6
121 const Sequence< OUString > SvtSysLocaleOptions_Impl::GetPropertyNames()
123 const OUString pProperties[] =
125 PROPERTYNAME_LOCALE,
126 PROPERTYNAME_UILOCALE,
127 PROPERTYNAME_CURRENCY,
128 PROPERTYNAME_DECIMALSEPARATOR,
129 PROPERTYNAME_DATEPATTERNS,
130 PROPERTYNAME_IGNORELANGCHANGE
132 const Sequence< OUString > seqPropertyNames( pProperties, PROPERTYCOUNT );
133 return seqPropertyNames;
136 SvtSysLocaleOptions_Impl::SvtSysLocaleOptions_Impl()
137 : ConfigItem( ROOTNODE_SYSLOCALE )
138 , m_aRealLocale( LANGUAGE_SYSTEM)
139 , m_aRealUILocale( LANGUAGE_SYSTEM)
140 , m_bDecimalSeparator( true )
141 , m_bIgnoreLanguageChange( false)
142 , m_bROLocale(CFG_READONLY_DEFAULT)
143 , m_bROUILocale(CFG_READONLY_DEFAULT)
144 , m_bROCurrency(CFG_READONLY_DEFAULT)
145 , m_bRODatePatterns(CFG_READONLY_DEFAULT)
146 , m_bRODecimalSeparator(false)
147 , m_bROIgnoreLanguageChange(false)
150 const Sequence< OUString > aNames = GetPropertyNames();
151 Sequence< Any > aValues = GetProperties( aNames );
152 Sequence< sal_Bool > aROStates = GetReadOnlyStates( aNames );
153 const Any* pValues = aValues.getConstArray();
154 const sal_Bool* pROStates = aROStates.getConstArray();
155 DBG_ASSERT( aValues.getLength() == aNames.getLength(), "GetProperties failed" );
156 DBG_ASSERT( aROStates.getLength() == aNames.getLength(), "GetReadOnlyStates failed" );
157 if ( aValues.getLength() == aNames.getLength() && aROStates.getLength() == aNames.getLength() )
159 for ( sal_Int32 nProp = 0; nProp < aNames.getLength(); nProp++ )
161 if ( pValues[nProp].hasValue() )
163 switch ( nProp )
165 case PROPERTYHANDLE_LOCALE :
167 OUString aStr;
168 if ( pValues[nProp] >>= aStr )
169 m_aLocaleString = aStr;
170 else
172 SAL_WARN( "unotools.config", "Wrong property type!" );
174 m_bROLocale = pROStates[nProp];
176 break;
177 case PROPERTYHANDLE_UILOCALE :
179 OUString aStr;
180 if ( pValues[nProp] >>= aStr )
181 m_aUILocaleString = aStr;
182 else
184 SAL_WARN( "unotools.config", "Wrong property type!" );
186 m_bROUILocale = pROStates[nProp];
188 break;
189 case PROPERTYHANDLE_CURRENCY :
191 OUString aStr;
192 if ( pValues[nProp] >>= aStr )
193 m_aCurrencyString = aStr;
194 else
196 SAL_WARN( "unotools.config", "Wrong property type!" );
198 m_bROCurrency = pROStates[nProp];
200 break;
201 case PROPERTYHANDLE_DECIMALSEPARATOR:
203 bool bValue = false;
204 if ( pValues[nProp] >>= bValue )
205 m_bDecimalSeparator = bValue;
206 else
208 SAL_WARN( "unotools.config", "Wrong property type!" );
210 m_bRODecimalSeparator = pROStates[nProp];
212 break;
213 case PROPERTYHANDLE_DATEPATTERNS :
215 OUString aStr;
216 if ( pValues[nProp] >>= aStr )
217 m_aDatePatternsString = aStr;
218 else
220 SAL_WARN( "unotools.config", "Wrong property type!" );
222 m_bRODatePatterns = pROStates[nProp];
224 break;
225 case PROPERTYHANDLE_IGNORELANGCHANGE :
227 bool bValue = false;
228 if ( pValues[nProp] >>= bValue )
229 m_bIgnoreLanguageChange = bValue;
230 else
232 SAL_WARN( "unotools.config", "Wrong property type!" );
234 m_bROIgnoreLanguageChange = pROStates[nProp];
236 break;
237 default:
238 SAL_WARN( "unotools.config", "Wrong property type!" );
243 EnableNotification( aNames );
245 MakeRealLocale();
246 MakeRealUILocale();
249 SvtSysLocaleOptions_Impl::~SvtSysLocaleOptions_Impl()
251 if ( IsModified() )
252 Commit();
255 void SvtSysLocaleOptions_Impl::MakeRealLocale()
257 if (m_aLocaleString.isEmpty())
259 LanguageType nLang = MsLangId::getSystemLanguage();
260 m_aRealLocale.reset( nLang).makeFallback();
262 else
264 m_aRealLocale.reset( m_aLocaleString).makeFallback();
268 void SvtSysLocaleOptions_Impl::MakeRealUILocale()
270 if (m_aUILocaleString.isEmpty())
272 LanguageType nLang = MsLangId::getSystemUILanguage();
273 m_aRealUILocale.reset( nLang).makeFallback();
275 else
277 m_aRealUILocale.reset( m_aUILocaleString).makeFallback();
281 bool SvtSysLocaleOptions_Impl::IsReadOnly( SvtSysLocaleOptions::EOption eOption ) const
283 bool bReadOnly = CFG_READONLY_DEFAULT;
284 switch(eOption)
286 case SvtSysLocaleOptions::E_LOCALE :
288 bReadOnly = m_bROLocale;
289 break;
291 case SvtSysLocaleOptions::E_UILOCALE :
293 bReadOnly = m_bROUILocale;
294 break;
296 case SvtSysLocaleOptions::E_CURRENCY :
298 bReadOnly = m_bROCurrency;
299 break;
301 case SvtSysLocaleOptions::E_DATEPATTERNS :
303 bReadOnly = m_bRODatePatterns;
304 break;
307 return bReadOnly;
310 void SvtSysLocaleOptions_Impl::Commit()
312 const Sequence< OUString > aOrgNames = GetPropertyNames();
313 sal_Int32 nOrgCount = aOrgNames.getLength();
315 Sequence< OUString > aNames( nOrgCount );
316 Sequence< Any > aValues( nOrgCount );
318 OUString* pNames = aNames.getArray();
319 Any* pValues = aValues.getArray();
320 sal_Int32 nRealCount = 0;
322 for ( sal_Int32 nProp = 0; nProp < nOrgCount; nProp++ )
324 switch ( nProp )
326 case PROPERTYHANDLE_LOCALE :
328 if (!m_bROLocale)
330 pNames[nRealCount] = aOrgNames[nProp];
331 pValues[nRealCount] <<= m_aLocaleString;
332 ++nRealCount;
335 break;
336 case PROPERTYHANDLE_UILOCALE :
338 if (!m_bROUILocale)
340 pNames[nRealCount] = aOrgNames[nProp];
341 pValues[nRealCount] <<= m_aUILocaleString;
342 ++nRealCount;
345 break;
346 case PROPERTYHANDLE_CURRENCY :
348 if (!m_bROCurrency)
350 pNames[nRealCount] = aOrgNames[nProp];
351 pValues[nRealCount] <<= m_aCurrencyString;
352 ++nRealCount;
355 break;
356 case PROPERTYHANDLE_DECIMALSEPARATOR:
357 if( !m_bRODecimalSeparator )
359 pNames[nRealCount] = aOrgNames[nProp];
360 pValues[nRealCount] <<= m_bDecimalSeparator;
361 ++nRealCount;
363 break;
364 case PROPERTYHANDLE_DATEPATTERNS :
365 if (!m_bRODatePatterns)
367 pNames[nRealCount] = aOrgNames[nProp];
368 pValues[nRealCount] <<= m_aDatePatternsString;
369 ++nRealCount;
371 break;
372 case PROPERTYHANDLE_IGNORELANGCHANGE :
373 if (!m_bROIgnoreLanguageChange)
375 pNames[nRealCount] = aOrgNames[nProp];
376 pValues[nRealCount] <<= m_bIgnoreLanguageChange;
377 ++nRealCount;
379 break;
380 default:
381 SAL_WARN( "unotools.config", "invalid index to save a path" );
384 aNames.realloc(nRealCount);
385 aValues.realloc(nRealCount);
386 PutProperties( aNames, aValues );
387 ClearModified();
390 void SvtSysLocaleOptions_Impl::SetLocaleString( const OUString& rStr )
392 if (!m_bROLocale && rStr != m_aLocaleString )
394 m_aLocaleString = rStr;
395 MakeRealLocale();
396 LanguageTag::setConfiguredSystemLanguage( m_aRealLocale.getLanguageType() );
397 SetModified();
398 sal_uLong nHint = SYSLOCALEOPTIONS_HINT_LOCALE;
399 if ( m_aCurrencyString.isEmpty() )
400 nHint |= SYSLOCALEOPTIONS_HINT_CURRENCY;
401 NotifyListeners( nHint );
405 void SvtSysLocaleOptions_Impl::SetUILocaleString( const OUString& rStr )
407 if (!m_bROUILocale && rStr != m_aUILocaleString )
409 m_aUILocaleString = rStr;
411 // as we can't switch UILocale at runtime, we only store changes in the configuration
412 MakeRealUILocale();
413 SetModified();
414 NotifyListeners( SYSLOCALEOPTIONS_HINT_UILOCALE );
418 void SvtSysLocaleOptions_Impl::SetCurrencyString( const OUString& rStr )
420 if (!m_bROCurrency && rStr != m_aCurrencyString )
422 m_aCurrencyString = rStr;
423 SetModified();
424 NotifyListeners( SYSLOCALEOPTIONS_HINT_CURRENCY );
428 void SvtSysLocaleOptions_Impl::SetDatePatternsString( const OUString& rStr )
430 if (!m_bRODatePatterns && rStr != m_aDatePatternsString )
432 m_aDatePatternsString = rStr;
433 SetModified();
434 NotifyListeners( SYSLOCALEOPTIONS_HINT_DATEPATTERNS );
438 void SvtSysLocaleOptions_Impl::SetDecimalSeparatorAsLocale( bool bSet)
440 if(bSet != m_bDecimalSeparator)
442 m_bDecimalSeparator = bSet;
443 SetModified();
444 NotifyListeners( SYSLOCALEOPTIONS_HINT_DECSEP );
448 void SvtSysLocaleOptions_Impl::SetIgnoreLanguageChange( bool bSet)
450 if(bSet != m_bIgnoreLanguageChange)
452 m_bIgnoreLanguageChange = bSet;
453 SetModified();
454 NotifyListeners( SYSLOCALEOPTIONS_HINT_IGNORELANG );
458 void SvtSysLocaleOptions_Impl::Notify( const Sequence< OUString >& seqPropertyNames )
460 sal_uLong nHint = 0;
461 Sequence< Any > seqValues = GetProperties( seqPropertyNames );
462 Sequence< sal_Bool > seqROStates = GetReadOnlyStates( seqPropertyNames );
463 sal_Int32 nCount = seqPropertyNames.getLength();
464 for( sal_Int32 nProp = 0; nProp < nCount; ++nProp )
466 if( seqPropertyNames[nProp] == PROPERTYNAME_LOCALE )
468 DBG_ASSERT( seqValues[nProp].getValueTypeClass() == TypeClass_STRING, "Locale property type" );
469 seqValues[nProp] >>= m_aLocaleString;
470 m_bROLocale = seqROStates[nProp];
471 nHint |= SYSLOCALEOPTIONS_HINT_LOCALE;
472 if ( m_aCurrencyString.isEmpty() )
473 nHint |= SYSLOCALEOPTIONS_HINT_CURRENCY;
474 MakeRealLocale();
476 if( seqPropertyNames[nProp] == PROPERTYNAME_UILOCALE )
478 DBG_ASSERT( seqValues[nProp].getValueTypeClass() == TypeClass_STRING, "Locale property type" );
479 seqValues[nProp] >>= m_aUILocaleString;
480 m_bROUILocale = seqROStates[nProp];
481 nHint |= SYSLOCALEOPTIONS_HINT_UILOCALE;
482 MakeRealUILocale();
484 else if( seqPropertyNames[nProp] == PROPERTYNAME_CURRENCY )
486 DBG_ASSERT( seqValues[nProp].getValueTypeClass() == TypeClass_STRING, "Currency property type" );
487 seqValues[nProp] >>= m_aCurrencyString;
488 m_bROCurrency = seqROStates[nProp];
489 nHint |= SYSLOCALEOPTIONS_HINT_CURRENCY;
491 else if( seqPropertyNames[nProp] == PROPERTYNAME_DECIMALSEPARATOR )
493 seqValues[nProp] >>= m_bDecimalSeparator;
494 m_bRODecimalSeparator = seqROStates[nProp];
496 else if( seqPropertyNames[nProp] == PROPERTYNAME_IGNORELANGCHANGE )
498 seqValues[nProp] >>= m_bIgnoreLanguageChange;
499 m_bROIgnoreLanguageChange = seqROStates[nProp];
501 else if( seqPropertyNames[nProp] == PROPERTYNAME_DATEPATTERNS )
503 DBG_ASSERT( seqValues[nProp].getValueTypeClass() == TypeClass_STRING, "DatePatterns property type" );
504 seqValues[nProp] >>= m_aDatePatternsString;
505 m_bRODatePatterns = seqROStates[nProp];
506 nHint |= SYSLOCALEOPTIONS_HINT_DATEPATTERNS;
509 if ( nHint )
510 NotifyListeners( nHint );
513 SvtSysLocaleOptions::SvtSysLocaleOptions()
515 MutexGuard aGuard( GetMutex() );
516 if ( !pOptions )
518 pOptions = new SvtSysLocaleOptions_Impl;
520 ItemHolder1::holdConfigItem(E_SYSLOCALEOPTIONS);
522 ++nRefCount;
523 pOptions->AddListener(this);
526 SvtSysLocaleOptions::~SvtSysLocaleOptions()
528 MutexGuard aGuard( GetMutex() );
529 pOptions->RemoveListener(this);
530 if ( !--nRefCount )
532 delete pOptions;
533 pOptions = NULL;
537 // static
538 Mutex& SvtSysLocaleOptions::GetMutex()
540 static Mutex* pMutex = NULL;
541 if( !pMutex )
543 MutexGuard aGuard( Mutex::getGlobalMutex() );
544 if( !pMutex )
546 // #i77768# Due to a static reference in the toolkit lib
547 // we need a mutex that lives longer than the svl library.
548 // Otherwise the dtor would use a destructed mutex!!
549 pMutex = new Mutex;
552 return *pMutex;
555 bool SvtSysLocaleOptions::IsModified()
557 MutexGuard aGuard( GetMutex() );
558 return pOptions->IsModified();
561 void SvtSysLocaleOptions::Commit()
563 MutexGuard aGuard( GetMutex() );
564 pOptions->Commit();
567 void SvtSysLocaleOptions::BlockBroadcasts( bool bBlock )
569 MutexGuard aGuard( GetMutex() );
570 pOptions->BlockBroadcasts( bBlock );
573 const OUString& SvtSysLocaleOptions::GetLocaleConfigString() const
575 MutexGuard aGuard( GetMutex() );
576 return pOptions->GetLocaleString();
579 void SvtSysLocaleOptions::SetLocaleConfigString( const OUString& rStr )
581 MutexGuard aGuard( GetMutex() );
582 pOptions->SetLocaleString( rStr );
585 void SvtSysLocaleOptions::SetUILocaleConfigString( const OUString& rStr )
587 MutexGuard aGuard( GetMutex() );
588 pOptions->SetUILocaleString( rStr );
591 const OUString& SvtSysLocaleOptions::GetCurrencyConfigString() const
593 MutexGuard aGuard( GetMutex() );
594 return pOptions->GetCurrencyString();
597 void SvtSysLocaleOptions::SetCurrencyConfigString( const OUString& rStr )
599 MutexGuard aGuard( GetMutex() );
600 pOptions->SetCurrencyString( rStr );
603 const OUString& SvtSysLocaleOptions::GetDatePatternsConfigString() const
605 MutexGuard aGuard( GetMutex() );
606 return pOptions->GetDatePatternsString();
609 void SvtSysLocaleOptions::SetDatePatternsConfigString( const OUString& rStr )
611 MutexGuard aGuard( GetMutex() );
612 pOptions->SetDatePatternsString( rStr );
615 bool SvtSysLocaleOptions::IsDecimalSeparatorAsLocale() const
617 MutexGuard aGuard( GetMutex() );
618 return pOptions->IsDecimalSeparatorAsLocale();
621 void SvtSysLocaleOptions::SetDecimalSeparatorAsLocale( bool bSet)
623 MutexGuard aGuard( GetMutex() );
624 pOptions->SetDecimalSeparatorAsLocale(bSet);
627 bool SvtSysLocaleOptions::IsIgnoreLanguageChange() const
629 MutexGuard aGuard( GetMutex() );
630 return pOptions->IsIgnoreLanguageChange();
633 void SvtSysLocaleOptions::SetIgnoreLanguageChange( bool bSet)
635 MutexGuard aGuard( GetMutex() );
636 pOptions->SetIgnoreLanguageChange(bSet);
639 bool SvtSysLocaleOptions::IsReadOnly( EOption eOption ) const
641 MutexGuard aGuard( GetMutex() );
642 return pOptions->IsReadOnly( eOption );
645 // static
646 void SvtSysLocaleOptions::GetCurrencyAbbrevAndLanguage( OUString& rAbbrev,
647 LanguageType& eLang,
648 const OUString& rConfigString )
650 sal_Int32 nDelim = rConfigString.indexOf( '-' );
651 if ( nDelim >= 0 )
653 rAbbrev = rConfigString.copy( 0, nDelim );
654 OUString aIsoStr( rConfigString.copy( nDelim+1 ) );
655 eLang = LanguageTag::convertToLanguageTypeWithFallback( aIsoStr );
657 else
659 rAbbrev = rConfigString;
660 eLang = (rAbbrev.isEmpty() ? LANGUAGE_SYSTEM : LANGUAGE_NONE);
664 // static
665 OUString SvtSysLocaleOptions::CreateCurrencyConfigString(
666 const OUString& rAbbrev, LanguageType eLang )
668 OUString aIsoStr( LanguageTag::convertToBcp47( eLang ) );
669 if ( !aIsoStr.isEmpty() )
671 OUStringBuffer aStr( rAbbrev.getLength() + 1 + aIsoStr.getLength() );
672 aStr.append( rAbbrev );
673 aStr.append( '-' );
674 aStr.append( aIsoStr );
675 return aStr.makeStringAndClear();
677 else
678 return rAbbrev;
681 // static
682 void SvtSysLocaleOptions::SetCurrencyChangeLink( const Link& rLink )
684 MutexGuard aGuard( GetMutex() );
685 DBG_ASSERT( !CurrencyChangeLink::get().IsSet(), "SvtSysLocaleOptions::SetCurrencyChangeLink: already set" );
686 CurrencyChangeLink::get() = rLink;
689 // static
690 const Link& SvtSysLocaleOptions::GetCurrencyChangeLink()
692 MutexGuard aGuard( GetMutex() );
693 return CurrencyChangeLink::get();
696 void SvtSysLocaleOptions::ConfigurationChanged( utl::ConfigurationBroadcaster* p, sal_uInt32 nHint )
698 if ( nHint & SYSLOCALEOPTIONS_HINT_CURRENCY )
700 const Link& rLink = GetCurrencyChangeLink();
701 if ( rLink.IsSet() )
702 rLink.Call( NULL );
705 ::utl::detail::Options::ConfigurationChanged( p, nHint );
708 LanguageTag SvtSysLocaleOptions::GetLanguageTag() const
710 return LanguageTag( GetLocaleConfigString() );
713 const LanguageTag & SvtSysLocaleOptions::GetRealLanguageTag() const
715 return pOptions->GetRealLocale();
718 const LanguageTag & SvtSysLocaleOptions::GetRealUILanguageTag() const
720 return pOptions->GetRealUILocale();
723 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */