if ((hDC = GetDC(infoPtr->hwndSelf)) != 0)
{
- if (infoPtr->dwStyle & ACS_TRANSPARENT)
- infoPtr->hbrushBG = (HBRUSH)SendMessageW(infoPtr->hwndNotify,
- WM_CTLCOLORSTATIC,
- (WPARAM)hDC, (LPARAM)infoPtr->hwndSelf);
EnterCriticalSection(&infoPtr->cs);
ANIMATE_DrawFrame(infoPtr, hDC);
LeaveCriticalSection(&infoPtr->cs);
{
HDC hDC = GetDC(infoPtr->hwndSelf);
- if (infoPtr->dwStyle & ACS_TRANSPARENT)
- infoPtr->hbrushBG = (HBRUSH)SendMessageW(infoPtr->hwndNotify,
- WM_CTLCOLORSTATIC,
- (WPARAM)hDC, (LPARAM)infoPtr->hwndSelf);
EnterCriticalSection(&infoPtr->cs);
ANIMATE_DrawFrame(infoPtr, hDC);
timeout = infoPtr->mah.dwMicroSecPerFrame;
if ((hDC = GetDC(infoPtr->hwndSelf)) != 0)
{
- if (infoPtr->dwStyle & ACS_TRANSPARENT)
- infoPtr->hbrushBG = (HBRUSH)SendMessageW(infoPtr->hwndNotify,
- WM_CTLCOLORSTATIC,
- (WPARAM)hDC, (LPARAM)infoPtr->hwndSelf);
ANIMATE_DrawFrame(infoPtr, hDC);
ReleaseDC(infoPtr->hwndSelf, hDC);
}
else
{
- if(infoPtr->dwStyle & ACS_TRANSPARENT)
- infoPtr->hbrushBG = (HBRUSH)SendMessageW(infoPtr->hwndNotify,
- WM_CTLCOLORSTATIC, 0,
- (LPARAM)infoPtr->hwndSelf);
-
TRACE("Using an animation thread\n");
infoPtr->hStopEvent = CreateEventW( NULL, TRUE, FALSE, NULL );
infoPtr->hThread = CreateThread(0, 0, ANIMATE_AnimationThread,
static BOOL ANIMATE_OpenW(ANIMATE_INFO *infoPtr, HINSTANCE hInstance, LPWSTR lpszName)
{
+ HDC hdc;
+
ANIMATE_Free(infoPtr);
if (!lpszName)
return FALSE;
}
+ hdc = GetDC(infoPtr->hwndSelf);
+ /* native looks at the top left pixel of the first frame here too. */
+ infoPtr->hbrushBG = (HBRUSH)SendMessageW(infoPtr->hwndNotify, WM_CTLCOLORSTATIC,
+ (WPARAM)hdc, (LPARAM)infoPtr->hwndSelf);
+ ReleaseDC(infoPtr->hwndSelf, hdc);
+
if (!(infoPtr->dwStyle & ACS_CENTER))
SetWindowPos(infoPtr->hwndSelf, 0, 0, 0, infoPtr->mah.dwWidth, infoPtr->mah.dwHeight,
SWP_NOACTIVATE | SWP_NOMOVE | SWP_NOZORDER);