summaryrefslogtreecommitdiff
path: root/forms/source/component/Currency.cxx
diff options
context:
space:
mode:
authorFrank Schönheit <fs@openoffice.org>2001-08-22 09:06:00 +0000
committerFrank Schönheit <fs@openoffice.org>2001-08-22 09:06:00 +0000
commit1640709dff7e6115765665efbd7f54fc68956e0c (patch)
treef31f20dd0beb2d7e9303257d9c87cfefdeacc61e /forms/source/component/Currency.cxx
parent863495bee9e38a9a37b724d3bbb9268251df32cf (diff)
#91235# calculate the default for CurrencySymbol differently (use SvtSysLocale)
Diffstat (limited to 'forms/source/component/Currency.cxx')
-rw-r--r--forms/source/component/Currency.cxx20
1 files changed, 12 insertions, 8 deletions
diff --git a/forms/source/component/Currency.cxx b/forms/source/component/Currency.cxx
index 2718a21ba389..526b222b03a2 100644
--- a/forms/source/component/Currency.cxx
+++ b/forms/source/component/Currency.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: Currency.cxx,v $
*
- * $Revision: 1.4 $
+ * $Revision: 1.5 $
*
- * last change: $Author: fs $ $Date: 2001-07-23 06:25:31 $
+ * last change: $Author: fs $ $Date: 2001-08-22 10:06:00 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -72,6 +72,9 @@
#ifndef _SV_SVAPP_HXX
#include <vcl/svapp.hxx>
#endif
+#ifndef INCLUDED_SVTOOLS_SYSLOCALE_HXX
+#include <svtools/syslocale.hxx>
+#endif
//.........................................................................
namespace frm
@@ -153,25 +156,26 @@ OCurrencyModel::OCurrencyModel(const Reference<XMultiServiceFactory>& _rxFactory
try
{
// get the system international informations
- LocaleDataWrapper aLocaleInfo(_rxFactory, Application::GetSettings().GetUILocale());
+ const LocaleDataWrapper& aLocaleInfo = SvtSysLocale().GetLocaleData();
+
::rtl::OUString sCurrencySymbol;
sal_Bool bPrependCurrencySymbol;
- switch (aLocaleInfo.getCurrPositiveFormat())
+ switch ( aLocaleInfo.getCurrPositiveFormat() )
{
case 0: // $1
- sCurrencySymbol = UniString(aLocaleInfo.getCurrSymbol());
+ sCurrencySymbol = String(aLocaleInfo.getCurrSymbol());
bPrependCurrencySymbol = sal_True;
break;
case 1: // 1$
- sCurrencySymbol = UniString(aLocaleInfo.getCurrSymbol());
+ sCurrencySymbol = String(aLocaleInfo.getCurrSymbol());
bPrependCurrencySymbol = sal_False;
break;
case 2: // $ 1
- sCurrencySymbol = ::rtl::OUString(UniString(aLocaleInfo.getCurrSymbol())) + ::rtl::OUString::createFromAscii(" ");
+ sCurrencySymbol = ::rtl::OUString(String(aLocaleInfo.getCurrSymbol())) + ::rtl::OUString::createFromAscii(" ");
bPrependCurrencySymbol = sal_True;
break;
case 3: // 1 $
- sCurrencySymbol = ::rtl::OUString::createFromAscii(" ") + ::rtl::OUString(UniString(aLocaleInfo.getCurrSymbol()));
+ sCurrencySymbol = ::rtl::OUString::createFromAscii(" ") + ::rtl::OUString(String(aLocaleInfo.getCurrSymbol()));
bPrependCurrencySymbol = sal_False;
break;
}