kernelbase: Reimplement LOCALE_*CURRNAME/CURRENCY in GetLocaleInfoW/Ex using the locale.nls data.

Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Alexandre Julliard 2022-03-29 08:36:41 +02:00
parent 37278557dd
commit 62cd33e6b0
2 changed files with 6 additions and 6 deletions

View File

@ -970,10 +970,10 @@ static int get_locale_info( const NLS_LOCALE_DATA *locale, LCID lcid, LCTYPE typ
return -1; return -1;
case LOCALE_SCURRENCY: case LOCALE_SCURRENCY:
return -1; return locale_return_string( locale->scurrency, type, buffer, len );
case LOCALE_SINTLSYMBOL: case LOCALE_SINTLSYMBOL:
return -1; return locale_return_string( locale->sintlsymbol, type, buffer, len );
case LOCALE_SMONDECIMALSEP: case LOCALE_SMONDECIMALSEP:
return -1; return -1;
@ -1241,10 +1241,10 @@ static int get_locale_info( const NLS_LOCALE_DATA *locale, LCID lcid, LCTYPE typ
return -1; return -1;
case LOCALE_SENGCURRNAME: case LOCALE_SENGCURRNAME:
return -1; return locale_return_string( locale->sengcurrname, type, buffer, len );
case LOCALE_SNATIVECURRNAME: case LOCALE_SNATIVECURRNAME:
return -1; return locale_return_string( locale->snativecurrname, type, buffer, len );
case LOCALE_ICALENDARTYPE: case LOCALE_ICALENDARTYPE:
return -1; return -1;

View File

@ -2460,10 +2460,10 @@ static void test_VarParseNumFromStrMisc(void)
lcid = MAKELCID(MAKELANGID(LANG_FRENCH,SUBLANG_FRENCH_SWISS),SORT_DEFAULT); lcid = MAKELCID(MAKELANGID(LANG_FRENCH,SUBLANG_FRENCH_SWISS),SORT_DEFAULT);
WCONVERT(L"3CHF", NUMPRS_CURRENCY|NUMPRS_USE_ALL); WCONVERT(L"3CHF", NUMPRS_CURRENCY|NUMPRS_USE_ALL);
/* Windows <= 8.1 uses an old currency symbol: "fr. 5" */ /* Windows <= 8.1 uses an old currency symbol: "fr. 5" */
todo_wine ok(hres == S_OK || broken(hres == DISP_E_TYPEMISMATCH), "returned %08lx\n", hres); ok(hres == S_OK || broken(hres == DISP_E_TYPEMISMATCH), "returned %08lx\n", hres);
if (hres == S_OK) if (hres == S_OK)
{ {
todo_wine EXPECT(1,NUMPRS_CURRENCY|NUMPRS_USE_ALL,NUMPRS_CURRENCY,4,0,0); EXPECT(1,NUMPRS_CURRENCY|NUMPRS_USE_ALL,NUMPRS_CURRENCY,4,0,0);
EXPECT2(3,FAILDIG); EXPECT2(3,FAILDIG);
} }