X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/2c40e41c4ed3127df0136077360a9de41b6192c8..e7ca6139d062c37cc7c056b6647097e999b714cd:/src/msw/region.cpp?ds=sidebyside diff --git a/src/msw/region.cpp b/src/msw/region.cpp index 6a37460c6a..c91f276350 100644 --- a/src/msw/region.cpp +++ b/src/msw/region.cpp @@ -103,6 +103,22 @@ wxRegion::wxRegion(const wxRect& rect) M_REGION = ::CreateRectRgn(rect.x, rect.y, rect.x + rect.width, rect.y + rect.height); } +wxRegion::wxRegion(size_t n, const wxPoint *points, int fillStyle) +{ +#ifdef __WXMICROWIN__ + m_refData = NULL; + M_REGION = NULL; +#else + m_refData = new wxRegionRefData; + M_REGION = ::CreatePolygonRgn + ( + (POINT*)points, + n, + fillStyle == wxODDEVEN_RULE ? ALTERNATE : WINDING + ); +#endif +} + /* * Destroy the region. */