gdiplus: Implement GdipCombineRegionPath.
This commit is contained in:
parent
2a445d0ebd
commit
93eae5e83f
|
@ -252,8 +252,38 @@ GpStatus WINGDIPAPI GdipCloneRegion(GpRegion *region, GpRegion **clone)
|
||||||
|
|
||||||
GpStatus WINGDIPAPI GdipCombineRegionPath(GpRegion *region, GpPath *path, CombineMode mode)
|
GpStatus WINGDIPAPI GdipCombineRegionPath(GpRegion *region, GpPath *path, CombineMode mode)
|
||||||
{
|
{
|
||||||
FIXME("(%p %p %d): stub\n", region, path, mode);
|
GpRegion *path_region;
|
||||||
return NotImplemented;
|
region_element *left, *right = NULL;
|
||||||
|
GpStatus stat;
|
||||||
|
|
||||||
|
TRACE("%p %p %d\n", region, path, mode);
|
||||||
|
|
||||||
|
if (!(region && path))
|
||||||
|
return InvalidParameter;
|
||||||
|
|
||||||
|
stat = GdipCreateRegionPath(path, &path_region);
|
||||||
|
if (stat != Ok)
|
||||||
|
return stat;
|
||||||
|
|
||||||
|
left = GdipAlloc(sizeof(region_element));
|
||||||
|
if (!left)
|
||||||
|
goto out;
|
||||||
|
*left = region->node;
|
||||||
|
|
||||||
|
stat = clone_element(&path_region->node, &right);
|
||||||
|
if (stat != Ok)
|
||||||
|
goto out;
|
||||||
|
|
||||||
|
fuse_region(region, left, right, mode);
|
||||||
|
|
||||||
|
GdipDeleteRegion(path_region);
|
||||||
|
return Ok;
|
||||||
|
|
||||||
|
out:
|
||||||
|
GdipFree(left);
|
||||||
|
delete_element(right);
|
||||||
|
GdipDeleteRegion(path_region);
|
||||||
|
return stat;
|
||||||
}
|
}
|
||||||
|
|
||||||
GpStatus WINGDIPAPI GdipCombineRegionRect(GpRegion *region,
|
GpStatus WINGDIPAPI GdipCombineRegionRect(GpRegion *region,
|
||||||
|
|
|
@ -70,7 +70,6 @@ static void test_getregiondata(void)
|
||||||
status = GdipGetRegionDataSize(region, &needed);
|
status = GdipGetRegionDataSize(region, &needed);
|
||||||
ok(status == Ok, "status %08x\n", status);
|
ok(status == Ok, "status %08x\n", status);
|
||||||
expect(20, needed);
|
expect(20, needed);
|
||||||
todo_wine
|
|
||||||
status = GdipGetRegionData(region, (BYTE*)buf, sizeof(buf), &needed);
|
status = GdipGetRegionData(region, (BYTE*)buf, sizeof(buf), &needed);
|
||||||
ok(status == Ok, "status %08x\n", status);
|
ok(status == Ok, "status %08x\n", status);
|
||||||
expect(20, needed);
|
expect(20, needed);
|
||||||
|
|
Loading…
Reference in New Issue