https://git.reactos.org/?p=reactos.git;a=commitdiff;h=bd9a4499a810a936fe661…
commit bd9a4499a810a936fe66143d141e107d3012a39f
Author: Katayama Hirofumi MZ <katayama.hirofumi.mz(a)gmail.com>
AuthorDate: Fri Aug 24 20:37:59 2018 +0900
Commit: Hermès BÉLUSCA - MAÏTO <hermes.belusca-maito(a)reactos.org>
CommitDate: Fri Aug 24 13:37:59 2018 +0200
[WIN32SS][NTGDI] Extend PATH_FillPath as PATH_FillPathEx (#798)
The new PATH_FillPathEx function takes an additional PBRUSH parameter.
CORE-2527
---
win32ss/gdi/ntgdi/bitblt.c | 1 -
win32ss/gdi/ntgdi/path.c | 12 +++++++++++-
win32ss/gdi/ntgdi/path.h | 2 ++
win32ss/gdi/ntgdi/region.h | 7 -------
4 files changed, 13 insertions(+), 9 deletions(-)
diff --git a/win32ss/gdi/ntgdi/bitblt.c b/win32ss/gdi/ntgdi/bitblt.c
index 38c92e3bb2..8e9fac9286 100644
--- a/win32ss/gdi/ntgdi/bitblt.c
+++ b/win32ss/gdi/ntgdi/bitblt.c
@@ -1122,7 +1122,6 @@ IntGdiBitBltRgn(
return bResult;
}
-static
BOOL
IntGdiFillRgn(
_In_ PDC pdc,
diff --git a/win32ss/gdi/ntgdi/path.c b/win32ss/gdi/ntgdi/path.c
index f4cc24951a..1bc5e2fb5f 100644
--- a/win32ss/gdi/ntgdi/path.c
+++ b/win32ss/gdi/ntgdi/path.c
@@ -1457,6 +1457,16 @@ FASTCALL
PATH_FillPath(
PDC dc,
PPATH pPath)
+{
+ return PATH_FillPathEx(dc, pPath, NULL);
+}
+
+BOOL
+FASTCALL
+PATH_FillPathEx(
+ PDC dc,
+ PPATH pPath,
+ PBRUSH pbrFill)
{
INT mapMode, graphicsMode;
SIZE ptViewportExt, ptWindowExt;
@@ -1517,7 +1527,7 @@ PATH_FillPath(
pdcattr->iGraphicsMode = graphicsMode;
/* Paint the region */
- IntGdiPaintRgn(dc, Rgn);
+ IntGdiFillRgn(dc, Rgn, pbrFill);
REGION_Delete(Rgn);
/* Restore the old mapping mode */
IntGdiSetMapMode(dc, mapMode);
diff --git a/win32ss/gdi/ntgdi/path.h b/win32ss/gdi/ntgdi/path.h
index f80113564e..9c5f63dabe 100644
--- a/win32ss/gdi/ntgdi/path.h
+++ b/win32ss/gdi/ntgdi/path.h
@@ -92,6 +92,7 @@ BOOL FASTCALL PATH_AddEntry (PPATH pPath, const POINT *pPoint, BYTE
flags);
BOOL FASTCALL PATH_AddFlatBezier (PPATH pPath, POINT *pt, BOOL closed);
BOOL FASTCALL PATH_DoArcPart (PPATH pPath, FLOAT_POINT corners[], double angleStart,
double angleEnd, BYTE startEntryType);
BOOL FASTCALL PATH_FillPath( PDC dc, PPATH pPath );
+BOOL FASTCALL PATH_FillPathEx(PDC dc, PPATH pPath, PBRUSH pbrFill);
PPATH FASTCALL PATH_FlattenPath (PPATH pPath);
VOID FASTCALL PATH_NormalizePoint (FLOAT_POINT corners[], const FLOAT_POINT *pPoint,
double *pX, double *pY);
@@ -107,3 +108,4 @@ VOID FASTCALL IntGetCurrentPositionEx(PDC dc, LPPOINT pt);
BOOL PATH_RestorePath( DC *, DC *);
BOOL PATH_SavePath( DC *, DC *);
+BOOL IntGdiFillRgn(PDC pdc, PREGION prgn, PBRUSH pbrFill);
diff --git a/win32ss/gdi/ntgdi/region.h b/win32ss/gdi/ntgdi/region.h
index abf053c462..0d4f454daa 100644
--- a/win32ss/gdi/ntgdi/region.h
+++ b/win32ss/gdi/ntgdi/region.h
@@ -96,10 +96,3 @@ GreCreateFrameRgn(
PREGION
FASTCALL
IntSysCreateRectpRgn(INT LeftRect, INT TopRect, INT RightRect, INT BottomRect);
-
-// FIXME: move this
-BOOL
-FASTCALL
-IntGdiPaintRgn(
- _In_ PDC pdc,
- _In_ PREGION prgn);