diff --git a/dlls/gdiplus/gdiplus.spec b/dlls/gdiplus/gdiplus.spec index d6971f9aa13..4f6b300efe3 100644 --- a/dlls/gdiplus/gdiplus.spec +++ b/dlls/gdiplus/gdiplus.spec @@ -18,7 +18,7 @@ @ stub GdipAddPathEllipseI @ stdcall GdipAddPathLine2(ptr ptr long) @ stdcall GdipAddPathLine2I(ptr ptr long) -@ stub GdipAddPathLine +@ stdcall GdipAddPathLine(ptr long long long long) @ stdcall GdipAddPathLineI(ptr long long long long) @ stdcall GdipAddPathPath(ptr ptr long) @ stub GdipAddPathPie diff --git a/dlls/gdiplus/graphicspath.c b/dlls/gdiplus/graphicspath.c index 0375f8e7464..d7be43e7bfa 100644 --- a/dlls/gdiplus/graphicspath.c +++ b/dlls/gdiplus/graphicspath.c @@ -247,7 +247,7 @@ GpStatus WINGDIPAPI GdipAddPathLine2I(GpPath *path, GDIPCONST GpPoint *points, I return stat; } -GpStatus WINGDIPAPI GdipAddPathLineI(GpPath *path, INT x1, INT y1, INT x2, INT y2) +GpStatus WINGDIPAPI GdipAddPathLine(GpPath *path, REAL x1, REAL y1, REAL x2, REAL y2) { INT old_count; @@ -259,10 +259,10 @@ GpStatus WINGDIPAPI GdipAddPathLineI(GpPath *path, INT x1, INT y1, INT x2, INT y old_count = path->pathdata.Count; - path->pathdata.Points[old_count].X = (REAL) x1; - path->pathdata.Points[old_count].Y = (REAL) y1; - path->pathdata.Points[old_count + 1].X = (REAL) x2; - path->pathdata.Points[old_count + 1].Y = (REAL) y2; + path->pathdata.Points[old_count].X = x1; + path->pathdata.Points[old_count].Y = y1; + path->pathdata.Points[old_count + 1].X = x2; + path->pathdata.Points[old_count + 1].Y = y2; path->pathdata.Types[old_count] = (path->newfigure ? PathPointTypeStart : PathPointTypeLine); @@ -274,6 +274,11 @@ GpStatus WINGDIPAPI GdipAddPathLineI(GpPath *path, INT x1, INT y1, INT x2, INT y return Ok; } +GpStatus WINGDIPAPI GdipAddPathLineI(GpPath *path, INT x1, INT y1, INT x2, INT y2) +{ + return GdipAddPathLine(path, (REAL)x1, (REAL)y1, (REAL)x2, (REAL)y2); +} + GpStatus WINGDIPAPI GdipAddPathPath(GpPath *path, GDIPCONST GpPath* addingPath, BOOL connect) {