riched20/tests: Use InflateRect() too when expanding in just one axis.
Michael Stefaniuc
mstefani at redhat.de
Sat Jul 9 06:50:02 CDT 2016
Signed-off-by: Michael Stefaniuc <mstefani at redhat.de>
---
dlls/riched20/tests/editor.c | 18 ++++++------------
1 file changed, 6 insertions(+), 12 deletions(-)
diff --git a/dlls/riched20/tests/editor.c b/dlls/riched20/tests/editor.c
index 76e2c97..218e20e 100644
--- a/dlls/riched20/tests/editor.c
+++ b/dlls/riched20/tests/editor.c
@@ -7047,8 +7047,7 @@ static void test_format_rect(void)
GetClientRect(hwnd, &clientRect);
expected = clientRect;
- expected.left += 1;
- expected.right -= 1;
+ InflateRect(&expected, -1, 0);
SendMessageA(hwnd, EM_GETRECT, 0, (LPARAM)&rc);
ok(EqualRect(&rc, &expected), "rect %s != %s\n", wine_dbgstr_rect(&rc),
wine_dbgstr_rect(&expected));
@@ -7143,8 +7142,7 @@ static void test_format_rect(void)
GetClientRect(hwnd, &clientRect);
expected = clientRect;
- expected.left += 1;
- expected.right -= 1;
+ InflateRect(&expected, -1, 0);
SendMessageA(hwnd, EM_GETRECT, 0, (LPARAM)&rc);
ok(EqualRect(&rc, &expected), "rect %s != %s\n", wine_dbgstr_rect(&rc),
wine_dbgstr_rect(&expected));
@@ -7153,8 +7151,7 @@ static void test_format_rect(void)
GetClientRect(hwnd, &clientRect);
expected = clientRect;
- expected.left += 1;
- expected.right -= 1;
+ InflateRect(&expected, -1, 0);
SendMessageA(hwnd, EM_GETRECT, 0, (LPARAM)&rc);
ok(EqualRect(&rc, &expected), "rect %s != %s\n", wine_dbgstr_rect(&rc),
wine_dbgstr_rect(&expected));
@@ -7163,8 +7160,7 @@ static void test_format_rect(void)
GetClientRect(hwnd, &clientRect);
expected = clientRect;
- expected.left += 1;
- expected.right -= 1;
+ InflateRect(&expected, -1, 0);
SendMessageA(hwnd, EM_GETRECT, 0, (LPARAM)&rc);
ok(EqualRect(&rc, &expected), "rect %s != %s\n", wine_dbgstr_rect(&rc),
wine_dbgstr_rect(&expected));
@@ -7180,9 +7176,8 @@ static void test_format_rect(void)
GetClientRect(hwnd, &clientRect);
expected = clientRect;
- expected.left += 1;
expected.top += 1;
- expected.right -= 1;
+ InflateRect(&expected, -1, 0);
SendMessageA(hwnd, EM_GETRECT, 0, (LPARAM)&rc);
ok(EqualRect(&rc, &expected), "rect %s != %s\n", wine_dbgstr_rect(&rc),
wine_dbgstr_rect(&expected));
@@ -7191,8 +7186,7 @@ static void test_format_rect(void)
InflateRect(&rc, -5, -5);
expected = rc;
expected.top -= 1;
- expected.left -= 1;
- expected.right += 1;
+ InflateRect(&expected, 1, 0);
SendMessageA(hwnd, EM_SETRECT, 0, (LPARAM)&rc);
SendMessageA(hwnd, EM_GETRECT, 0, (LPARAM)&rc);
ok(EqualRect(&rc, &expected), "rect %s != %s\n", wine_dbgstr_rect(&rc),
--
2.4.11
More information about the wine-patches
mailing list