mirror of
https://github.com/reactos/reactos.git
synced 2024-09-30 22:47:28 +00:00
Add and fix path calls. This allows more drawing tests (Area.exe by Yian)to pass based on observation.
svn path=/trunk/; revision=34198
This commit is contained in:
parent
3150ee723e
commit
eb8611b79f
|
@ -76,10 +76,7 @@ IntGdiPolygon(PDC dc,
|
|||
UnsafePoints[CurrentPoint].x += dc->ptlDCOrig.x;
|
||||
UnsafePoints[CurrentPoint].y += dc->ptlDCOrig.y;
|
||||
}
|
||||
|
||||
if (PATH_IsPathOpen(dc->DcLevel))
|
||||
ret = PATH_Polygon(dc, UnsafePoints, Count );
|
||||
else
|
||||
// No need to have path here.
|
||||
{
|
||||
DestRect.left = UnsafePoints[0].x;
|
||||
DestRect.right = UnsafePoints[0].x;
|
||||
|
@ -157,6 +154,8 @@ IntGdiPolyPolygon(DC *dc,
|
|||
LPINT PolyCounts,
|
||||
int Count)
|
||||
{
|
||||
if (PATH_IsPathOpen(dc->DcLevel))
|
||||
return PATH_PolyPolygon ( dc, Points, PolyCounts, Count);
|
||||
while (--Count >=0)
|
||||
{
|
||||
if (!IntGdiPolygon ( dc, Points, *PolyCounts ))
|
||||
|
@ -225,15 +224,6 @@ NtGdiEllipse(
|
|||
|
||||
if ((nLeftRect == nRightRect) || (nTopRect == nBottomRect)) return TRUE;
|
||||
|
||||
if (nRightRect < nLeftRect)
|
||||
{
|
||||
INT tmp = nRightRect; nRightRect = nLeftRect; nLeftRect = tmp;
|
||||
}
|
||||
if (nBottomRect < nTopRect)
|
||||
{
|
||||
INT tmp = nBottomRect; nBottomRect = nTopRect; nTopRect = tmp;
|
||||
}
|
||||
|
||||
/*
|
||||
* Get pointers to all necessary GDI objects.
|
||||
*/
|
||||
|
@ -244,6 +234,7 @@ NtGdiEllipse(
|
|||
SetLastWin32Error(ERROR_INVALID_HANDLE);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
if (dc->DC_Type == DC_TYPE_INFO)
|
||||
{
|
||||
DC_UnlockDc(dc);
|
||||
|
@ -251,6 +242,22 @@ NtGdiEllipse(
|
|||
return TRUE;
|
||||
}
|
||||
|
||||
if (PATH_IsPathOpen(dc->DcLevel))
|
||||
{
|
||||
ret = PATH_Ellipse(dc, nLeftRect, nTopRect, nRightRect, nBottomRect);
|
||||
DC_UnlockDc(dc);
|
||||
return ret;
|
||||
}
|
||||
|
||||
if (nRightRect < nLeftRect)
|
||||
{
|
||||
INT tmp = nRightRect; nRightRect = nLeftRect; nLeftRect = tmp;
|
||||
}
|
||||
if (nBottomRect < nTopRect)
|
||||
{
|
||||
INT tmp = nBottomRect; nBottomRect = nTopRect; nTopRect = tmp;
|
||||
}
|
||||
|
||||
Dc_Attr = dc->pDc_Attr;
|
||||
if(!Dc_Attr) Dc_Attr = &dc->Dc_Attr;
|
||||
|
||||
|
|
|
@ -102,17 +102,15 @@ IntGdiLineTo(DC *dc,
|
|||
if (PATH_IsPathOpen(dc->DcLevel))
|
||||
{
|
||||
Ret = PATH_LineTo(dc, XEnd, YEnd);
|
||||
//#if 0
|
||||
if (Ret)
|
||||
{
|
||||
// FIXME - PATH_LineTo should maybe do this...
|
||||
// FIXME - PATH_LineTo should maybe do this? No
|
||||
Dc_Attr->ptlCurrent.x = XEnd;
|
||||
Dc_Attr->ptlCurrent.y = YEnd;
|
||||
Dc_Attr->ptfxCurrent = Dc_Attr->ptlCurrent;
|
||||
CoordLPtoDP(dc, &Dc_Attr->ptfxCurrent); // Update fx
|
||||
Dc_Attr->ulDirty_ &= ~(DIRTY_PTLCURRENT|DIRTY_PTFXCURRENT|DIRTY_STYLESTATE);
|
||||
}
|
||||
//#endif
|
||||
return Ret;
|
||||
}
|
||||
else
|
||||
|
@ -362,6 +360,9 @@ IntGdiPolyPolyline(DC *dc,
|
|||
pts = pt;
|
||||
pc = PolyPoints;
|
||||
|
||||
if (PATH_IsPathOpen(dc->DcLevel))
|
||||
return PATH_PolyPolyline( dc, pt, PolyPoints, Count );
|
||||
|
||||
for (i = 0; i < Count; i++)
|
||||
{
|
||||
ret = IntGdiPolyline ( dc, pts, *pc );
|
||||
|
|
Loading…
Reference in a new issue