Module: wine
Branch: master
Commit: b8d01f9e1e8c44df5172c4cbfae627158930db72
URL: http://source.winehq.org/git/wine.git/?a=commit;h=b8d01f9e1e8c44df5172c4cbf…
Author: Alex Henrie <alexhenrie24(a)gmail.com>
Date: Mon Nov 20 22:54:35 2017 -0700
comctl32/tests: Detect and handle an RTL locale.
Signed-off-by: Alex Henrie <alexhenrie24(a)gmail.com>
Signed-off-by: Alexandre Julliard <julliard(a)winehq.org>
---
dlls/comctl32/tests/propsheet.c | 32 +++++++++++++++++++++++++++++---
1 file changed, 29 insertions(+), 3 deletions(-)
diff --git a/dlls/comctl32/tests/propsheet.c b/dlls/comctl32/tests/propsheet.c
index a3f910d..ec53e6b 100644
--- a/dlls/comctl32/tests/propsheet.c
+++ b/dlls/comctl32/tests/propsheet.c
@@ -29,11 +29,19 @@
static HWND parenthwnd;
static HWND sheethwnd;
+static BOOL rtl;
static LONG active_page = -1;
#define IDC_APPLY_BUTTON 12321
+static void detect_locale(void)
+{
+ DWORD reading_layout;
+ rtl = GetLocaleInfoW(LOCALE_USER_DEFAULT, LOCALE_IREADINGLAYOUT | LOCALE_RETURN_NUMBER,
+ (void *)&reading_layout, sizeof(reading_layout)) && reading_layout == 1;
+}
+
/* try to make sure pending X events have been processed before continuing */
static void flush_events(void)
{
@@ -496,19 +504,28 @@ static void test_buttons(void)
button = GetDlgItem(hdlg, IDCANCEL);
GetWindowRect(button, &rc);
ok(rc.top == top, "Cancel button should have same top as OK button\n");
- ok(rc.left > prevRight, "Cancel button should be to the right of OK button\n");
+ if (rtl)
+ ok(rc.left < prevRight, "Cancel button should be to the left of OK button\n");
+ else
+ ok(rc.left > prevRight, "Cancel button should be to the right of OK button\n");
prevRight = rc.right;
button = GetDlgItem(hdlg, IDC_APPLY_BUTTON);
GetWindowRect(button, &rc);
ok(rc.top == top, "Apply button should have same top as OK button\n");
- ok(rc.left > prevRight, "Apply button should be to the right of Cancel button\n");
+ if (rtl)
+ ok(rc.left < prevRight, "Apply button should be to the left of Cancel button\n");
+ else
+ ok(rc.left > prevRight, "Apply button should be to the right of Cancel button\n");
prevRight = rc.right;
button = GetDlgItem(hdlg, IDHELP);
GetWindowRect(button, &rc);
ok(rc.top == top, "Help button should have same top as OK button\n");
- ok(rc.left > prevRight, "Help button should be to the right of Apply button\n");
+ if (rtl)
+ ok(rc.left < prevRight, "Help button should be to the left of Apply button\n");
+ else
+ ok(rc.left > prevRight, "Help button should be to the right of Apply button\n");
DestroyWindow(hdlg);
}
@@ -1124,6 +1141,15 @@ static void test_CreatePropertySheetPage(void)
START_TEST(propsheet)
{
+ detect_locale();
+ if (rtl)
+ {
+ /* use locale-specific RTL resources when on an RTL locale */
+ /* without this, propsheets on RTL locales use English LTR resources */
+ trace("RTL locale detected\n");
+ SetProcessDefaultLayout(LAYOUT_RTL);
+ }
+
test_title();
test_nopage();
test_disableowner();
Module: wine
Branch: master
Commit: 2f8c9d449b4107bbe1a81dc08ab9f20a752f8bb8
URL: http://source.winehq.org/git/wine.git/?a=commit;h=2f8c9d449b4107bbe1a81dc08…
Author: Jonathan Doron <jond(a)wizery.com>
Date: Mon Nov 20 16:08:10 2017 +0200
kernel32/tests: Test suspended process with new thread.
Test the exe imports resolve time if a new thread is being created in
a new suspended process.
Signed-off-by: Jonathan Doron <jond(a)wizery.com>
Signed-off-by: Alexandre Julliard <julliard(a)winehq.org>
---
dlls/kernel32/tests/process.c | 180 +++++++++++++++++++++++++++---------------
1 file changed, 118 insertions(+), 62 deletions(-)
Diff: http://source.winehq.org/git/wine.git/?a=commitdiff;h=2f8c9d449b4107bbe1a81…