Commit 89fe0a3f authored by Nikolay Sivov's avatar Nikolay Sivov Committed by Alexandre Julliard

uxtheme: Implement GetBufferedPaintTargetRect().

parent 9f9842ba
......@@ -223,10 +223,20 @@ HDC WINAPI GetBufferedPaintTargetDC(HPAINTBUFFER bufferhandle)
/***********************************************************************
* GetBufferedPaintTargetRect (UXTHEME.@)
*/
HRESULT WINAPI GetBufferedPaintTargetRect(HPAINTBUFFER hBufferedPaint, RECT *prc)
HRESULT WINAPI GetBufferedPaintTargetRect(HPAINTBUFFER bufferhandle, RECT *rect)
{
FIXME("Stub (%p %p)\n", hBufferedPaint, prc);
return E_NOTIMPL;
struct paintbuffer *buffer = get_buffer_obj(bufferhandle);
TRACE("(%p %p)\n", buffer, rect);
if (!rect)
return E_POINTER;
if (!buffer)
return E_FAIL;
*rect = buffer->rect;
return S_OK;
}
/***********************************************************************
......
......@@ -619,16 +619,20 @@ todo_wine
hdc = pGetBufferedPaintTargetDC(buffer);
ok(hdc == target, "Unexpected target hdc %p, original %p\n", hdc, target);
hr = pGetBufferedPaintTargetRect(NULL, NULL);
ok(hr == E_POINTER, "Unexpected return code %#x\n", hr);
hr = pGetBufferedPaintTargetRect(buffer, NULL);
todo_wine
ok(hr == E_POINTER, "Unexpected return code %#x\n", hr);
hr = pGetBufferedPaintTargetRect(NULL, &rect2);
ok(hr == E_FAIL, "Unexpected return code %#x\n", hr);
SetRectEmpty(&rect2);
hr = pGetBufferedPaintTargetRect(buffer, &rect2);
todo_wine {
ok(hr == S_OK, "Unexpected return code %#x\n", hr);
ok(EqualRect(&rect, &rect2), "Wrong target rect\n");
}
hr = pEndBufferedPaint(buffer, FALSE);
ok(hr == S_OK, "Unexpected return code %#x\n", hr);
......
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