diff options
author | Eike Rathke <ooo@erack.de> | 2011-08-04 23:43:09 +0200 |
---|---|---|
committer | Eike Rathke <ooo@erack.de> | 2011-08-05 12:33:20 +0200 |
commit | 93fb89212487e57ecaec48571018538a60b1dc8f (patch) | |
tree | bd1962428bfb6f003daa36918301296189c95a5d /svx/source | |
parent | db1b7178dde8daa8660becf35acf8362b5f4bd7e (diff) |
fdo#38956 related changes in split libs-core repository to support LCID changes
Diffstat (limited to 'svx/source')
-rw-r--r-- | svx/source/items/numfmtsh.cxx | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/svx/source/items/numfmtsh.cxx b/svx/source/items/numfmtsh.cxx index 8ad28a3e00c8..7b106ae2d1d2 100644 --- a/svx/source/items/numfmtsh.cxx +++ b/svx/source/items/numfmtsh.cxx @@ -289,6 +289,20 @@ sal_Bool SvxNumberFormatShell::AddFormat( String& rFormat, xub_StrLen& rErrPos, bInserted = pFormatter->PutEntry( rFormat, rErrPos, nCurCategory, nAddKey, eCurLanguage ); + if (bInserted) + { + // May be sorted under a different locale if LCID was parsed. + const SvNumberformat* pEntry = pFormatter->GetEntry( nAddKey); + if (pEntry) + { + LanguageType nLang = pEntry->GetLanguage(); + if (eCurLanguage != nLang) + { + // Current language's list would not show entry, adapt. + eCurLanguage = nLang; + } + } + } } if ( bInserted ) // eingefuegt |