If the meta/clip intersection (Rao) region doesn't exist, return

either the meta or clip region if they do exist.
Remove the wine_todo's.
This commit is contained in:
Huw Davies 2005-10-11 19:55:01 +00:00 committed by Alexandre Julliard
parent c0c514b072
commit 22ab2046fb
2 changed files with 6 additions and 10 deletions

View File

@ -566,6 +566,8 @@ INT WINAPI GetRandomRgn(HDC hDC, HRGN hRgn, INT iCode)
break;
case 3:
rgn = dc->hMetaClipRgn;
if(!rgn) rgn = dc->hClipRgn;
if(!rgn) rgn = dc->hMetaRgn;
break;
case SYSRGN: /* == 4 */
rgn = dc->hVisRgn;

View File

@ -58,11 +58,8 @@ static void test_GetRandomRgn(void)
ret = GetRandomRgn(hdc, hrgn, 2);
ok(ret == 0, "GetRandomRgn rets %d\n", ret);
todo_wine
{
ret = GetRandomRgn(hdc, hrgn, 3);
ok(ret != 0, "GetRandomRgn rets %d\n", ret);
}
GetRgnBox(hrgn, &ret_rc);
ok(EqualRect(&rc, &ret_rc), "GetRandomRgn %ld,%ld - %ld,%ld\n",
ret_rc.left, ret_rc.top, ret_rc.right, ret_rc.bottom);
@ -78,11 +75,8 @@ static void test_GetRandomRgn(void)
ok(EqualRect(&rc, &ret_rc), "GetRandomRgn %ld,%ld - %ld,%ld\n",
ret_rc.left, ret_rc.top, ret_rc.right, ret_rc.bottom);
todo_wine
{
ret = GetRandomRgn(hdc, hrgn, 3);
ok(ret != 0, "GetRandomRgn rets %d\n", ret);
}
GetRgnBox(hrgn, &ret_rc);
ok(EqualRect(&rc, &ret_rc), "GetRandomRgn %ld,%ld - %ld,%ld\n",
ret_rc.left, ret_rc.top, ret_rc.right, ret_rc.bottom);