diff options
author | Eike Rathke <erack@redhat.com> | 2016-06-08 21:22:34 +0200 |
---|---|---|
committer | Eike Rathke <erack@redhat.com> | 2016-06-08 22:49:04 +0200 |
commit | 91640c080c7a0643cce95f605ca7774da4c4dd77 (patch) | |
tree | 646d40c1cc286e01ddba46e202e95e28871a038e /svl | |
parent | 333b644d112d94e3d675e5915b8b1e535b0841e4 (diff) |
make SvNumberFormatter::IsCompatible() static
Change-Id: Ic40d0852c8e0a8f0957fc782c85c1084c7fe265f
Diffstat (limited to 'svl')
-rw-r--r-- | svl/source/numbers/numfmuno.cxx | 9 | ||||
-rw-r--r-- | svl/source/numbers/zforlist.cxx | 6 |
2 files changed, 4 insertions, 11 deletions
diff --git a/svl/source/numbers/numfmuno.cxx b/svl/source/numbers/numfmuno.cxx index 0f87d6809b5e..0047c3478936 100644 --- a/svl/source/numbers/numfmuno.cxx +++ b/svl/source/numbers/numfmuno.cxx @@ -622,14 +622,7 @@ sal_Bool SAL_CALL SvNumberFormatsObj::isTypeCompatible( sal_Int16 nOldType, sal_ { ::osl::MutexGuard aGuard( m_aMutex ); - bool bRet = false; - SvNumberFormatter* pFormatter = rSupplier.GetNumberFormatter(); - if (pFormatter) - bRet = pFormatter->IsCompatible( nOldType, nNewType ); - else - throw uno::RuntimeException(); - - return bRet; + return SvNumberFormatter::IsCompatible( nOldType, nNewType ); } sal_Int32 SAL_CALL SvNumberFormatsObj::getFormatForLocale( sal_Int32 nKey, const lang::Locale& nLocale ) diff --git a/svl/source/numbers/zforlist.cxx b/svl/source/numbers/zforlist.cxx index 0747e0c2a326..9cfe4cc2e85a 100644 --- a/svl/source/numbers/zforlist.cxx +++ b/svl/source/numbers/zforlist.cxx @@ -1146,8 +1146,8 @@ LanguageType SvNumberFormatter::GetLanguage() const return IniLnge; } -bool SvNumberFormatter::IsCompatible(short eOldType, - short eNewType) +// static +bool SvNumberFormatter::IsCompatible(short eOldType, short eNewType) { if (eOldType == eNewType) { @@ -1168,9 +1168,9 @@ bool SvNumberFormatter::IsCompatible(short eOldType, case css::util::NumberFormat::CURRENCY: case css::util::NumberFormat::SCIENTIFIC: case css::util::NumberFormat::FRACTION: -// case css::util::NumberFormat::LOGICAL: case css::util::NumberFormat::DEFINED: return true; + case css::util::NumberFormat::LOGICAL: default: return false; } |