- Use SetWindowPos to move the buddy window into position instead of

destroying it and recreating it at the new position.
- Clear the background in WM_VSCROLL to avoid problems with
  antialiased text drawing on top of itself multiple times.
This commit is contained in:
Robert Shearman 2005-04-15 14:08:39 +00:00 committed by Alexandre Julliard
parent 04efa1338c
commit 21f9465067
1 changed files with 5 additions and 7 deletions

View File

@ -917,7 +917,7 @@ DATETIME_VScroll (DATETIME_INFO *infoPtr, WORD wScroll)
DATETIME_SendDateTimeChangeNotify (infoPtr);
}
InvalidateRect(infoPtr->hwndSelf, NULL, FALSE);
InvalidateRect(infoPtr->hwndSelf, NULL, TRUE);
return 0;
}
@ -1010,12 +1010,10 @@ DATETIME_Size (DATETIME_INFO *infoPtr, WORD flags, INT width, INT height)
infoPtr->rcDraw = infoPtr->rcClient;
if (infoPtr->dwStyle & DTS_UPDOWN) {
/* the updown control seems to ignore SetWindowPos messages */
DestroyWindow(infoPtr->hUpdown);
/* hmmm... the updown control seems to ignore the width parameter */
infoPtr->hUpdown = CreateUpDownControl (WS_CHILD | WS_BORDER | WS_VISIBLE,
infoPtr->rcClient.right-14, 0, 20, infoPtr->rcClient.bottom,
infoPtr->hwndSelf, 1, 0, 0, UD_MAXVAL, UD_MINVAL, 0);
SetWindowPos(infoPtr->hUpdown, NULL,
infoPtr->rcClient.right-14, 0,
15, infoPtr->rcClient.bottom - infoPtr->rcClient.top,
SWP_NOACTIVATE | SWP_NOZORDER);
}
else {
/* set the size of the button that drops the calendar down */