summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEike Rathke <ooo@erack.de>2011-08-04 23:43:09 +0200
committerEike Rathke <ooo@erack.de>2011-08-05 12:33:20 +0200
commit513e2e78a9bb0861064f73c17000afd75239c7a6 (patch)
treeabbd33cbb304238f4c3728a6df2cad10f3009ab3
parentf1936c8785a497702f74747e7bb8a12ab5602fb4 (diff)
fdo#38956 related changes in split libs-core repository to support LCID changes
-rw-r--r--svx/source/items/numfmtsh.cxx14
1 files changed, 14 insertions, 0 deletions
diff --git a/svx/source/items/numfmtsh.cxx b/svx/source/items/numfmtsh.cxx
index 837fdea456..9f7081703b 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