riched20/tests: Use the system locale to determine rtl and multibyte behaviour.

Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Huw Davies 2021-03-08 13:45:45 +00:00 committed by Alexandre Julliard
parent 7a68ae5951
commit dc85e70be0
1 changed files with 4 additions and 4 deletions

View File

@ -615,7 +615,7 @@ static void test_EM_POSFROMCHAR(void)
"gg\n" "gg\n"
"hh\n"; "hh\n";
rtl = (GetLocaleInfoA(LOCALE_USER_DEFAULT, LOCALE_FONTSIGNATURE, rtl = (GetLocaleInfoA(LOCALE_SYSTEM_DEFAULT, LOCALE_FONTSIGNATURE,
(LPSTR) &sig, sizeof(LOCALESIGNATURE)) && (LPSTR) &sig, sizeof(LOCALESIGNATURE)) &&
(sig.lsUsb[3] & 0x08000000) != 0); (sig.lsUsb[3] & 0x08000000) != 0);
@ -771,7 +771,7 @@ static void test_EM_SETCHARFORMAT(void)
BOOL rtl; BOOL rtl;
DWORD expect_effects; DWORD expect_effects;
rtl = (GetLocaleInfoA(LOCALE_USER_DEFAULT, LOCALE_FONTSIGNATURE, rtl = (GetLocaleInfoA(LOCALE_SYSTEM_DEFAULT, LOCALE_FONTSIGNATURE,
(LPSTR) &sig, sizeof(LOCALESIGNATURE)) && (LPSTR) &sig, sizeof(LOCALESIGNATURE)) &&
(sig.lsUsb[3] & 0x08000000) != 0); (sig.lsUsb[3] & 0x08000000) != 0);
@ -5609,7 +5609,7 @@ static void test_EM_FORMATRANGE(void)
{"WINE\r\n\r\nwine\r\nwine", 5, 6} {"WINE\r\n\r\nwine\r\nwine", 5, 6}
}; };
skip_non_english = (PRIMARYLANGID(GetUserDefaultLangID()) != LANG_ENGLISH); skip_non_english = (PRIMARYLANGID(GetSystemDefaultLangID()) != LANG_ENGLISH);
if (skip_non_english) if (skip_non_english)
skip("Skipping some tests on non-English platform\n"); skip("Skipping some tests on non-English platform\n");
@ -8964,7 +8964,7 @@ START_TEST( editor )
* RICHED20.DLL, so the linker doesn't actually link to it. */ * RICHED20.DLL, so the linker doesn't actually link to it. */
hmoduleRichEdit = LoadLibraryA("riched20.dll"); hmoduleRichEdit = LoadLibraryA("riched20.dll");
ok(hmoduleRichEdit != NULL, "error: %d\n", (int) GetLastError()); ok(hmoduleRichEdit != NULL, "error: %d\n", (int) GetLastError());
is_lang_japanese = (PRIMARYLANGID(GetUserDefaultLangID()) == LANG_JAPANESE); is_lang_japanese = (PRIMARYLANGID(GetSystemDefaultLangID()) == LANG_JAPANESE);
test_WM_CHAR(); test_WM_CHAR();
test_EM_FINDTEXT(FALSE); test_EM_FINDTEXT(FALSE);