Commit 61925b7e authored by Alexandre Julliard's avatar Alexandre Julliard

gdi32: Return copies of the region in InquireVisRgn16 and GetClipRgn16.

parent 569f56e8
......@@ -3659,14 +3659,11 @@ DWORD WINAPI SetDCOrg16( HDC16 hdc16, INT16 x, INT16 y )
*/
HRGN16 WINAPI InquireVisRgn16( HDC16 hdc )
{
HRGN16 ret = 0;
DC * dc = get_dc_ptr( HDC_32(hdc) );
if (dc)
{
ret = HRGN_16(dc->hVisRgn);
release_dc_ptr( dc );
}
return ret;
static HRGN hrgn;
if (!hrgn) hrgn = CreateRectRgn( 0, 0, 0, 0 );
GetRandomRgn( HDC_32(hdc), hrgn, SYSRGN );
return HRGN_16(hrgn);
}
......@@ -3760,14 +3757,11 @@ INT16 WINAPI RestoreVisRgn16( HDC16 hdc16 )
*/
HRGN16 WINAPI GetClipRgn16( HDC16 hdc )
{
HRGN16 ret = 0;
DC * dc = get_dc_ptr( HDC_32(hdc) );
if (dc)
{
ret = HRGN_16(dc->hClipRgn);
release_dc_ptr( dc );
}
return ret;
static HRGN hrgn;
if (!hrgn) hrgn = CreateRectRgn( 0, 0, 0, 0 );
GetClipRgn( HDC_32(hdc), hrgn );
return HRGN_16(hrgn);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment