Repainting fixes/improvements. Use SWP_NOCOPYBITS for statusbars, don't activate when using DeferWindowPos and remove WM_WINDOWPOSCHANGED code (no longer necessary).
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@36821 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -1613,7 +1613,7 @@ wxWindowMSW::DoMoveSibling(WXHWND hwnd, int x, int y, int width, int height)
|
||||
if ( hdwp )
|
||||
{
|
||||
hdwp = ::DeferWindowPos(hdwp, (HWND)hwnd, NULL, x, y, width, height,
|
||||
SWP_NOZORDER);
|
||||
SWP_NOZORDER | SWP_NOOWNERZORDER | SWP_NOACTIVATE);
|
||||
if ( !hdwp )
|
||||
{
|
||||
wxLogLastError(_T("DeferWindowPos"));
|
||||
@@ -2394,28 +2394,6 @@ WXLRESULT wxWindowMSW::MSWWindowProc(WXUINT message, WXWPARAM wParam, WXLPARAM l
|
||||
break;
|
||||
#endif // !__WXWINCE__
|
||||
|
||||
#if !(defined(_WIN32_WCE) && _WIN32_WCE < 400)
|
||||
case WM_WINDOWPOSCHANGED:
|
||||
{
|
||||
WINDOWPOS *lpPos = (WINDOWPOS *)lParam;
|
||||
|
||||
if ( !(lpPos->flags & SWP_NOSIZE) )
|
||||
{
|
||||
RECT rc;
|
||||
::GetClientRect(GetHwnd(), &rc);
|
||||
|
||||
AutoHRGN hrgnClient(::CreateRectRgnIndirect(&rc));
|
||||
AutoHRGN hrgnNew(::CreateRectRgn(lpPos->x, lpPos->y,
|
||||
lpPos->cx, lpPos->cy));
|
||||
|
||||
// we need to invalidate any new exposed areas here
|
||||
// to force them to repaint
|
||||
if ( ::CombineRgn(hrgnNew, hrgnNew, hrgnClient, RGN_DIFF) != NULLREGION )
|
||||
::InvalidateRgn(GetHwnd(), hrgnNew, TRUE);
|
||||
}
|
||||
}
|
||||
break;
|
||||
#endif
|
||||
#if !defined(__WXMICROWIN__) && !defined(__WXWINCE__)
|
||||
case WM_ACTIVATEAPP:
|
||||
// This implicitly sends a wxEVT_ACTIVATE_APP event
|
||||
@@ -5402,12 +5380,12 @@ wxMouseState wxGetMouseState()
|
||||
ms.SetLeftDown( (GetAsyncKeyState(VK_LBUTTON) & (1<<15)) != 0 );
|
||||
ms.SetMiddleDown( (GetAsyncKeyState(VK_MBUTTON) & (1<<15)) != 0 );
|
||||
ms.SetRightDown( (GetAsyncKeyState(VK_RBUTTON) & (1<<15)) != 0 );
|
||||
|
||||
|
||||
ms.SetControlDown( (GetAsyncKeyState(VK_CONTROL) & (1<<15)) != 0 );
|
||||
ms.SetShiftDown( (GetAsyncKeyState(VK_SHIFT) & (1<<15)) != 0 );
|
||||
ms.SetAltDown( (GetAsyncKeyState(VK_MENU) & (1<<15)) != 0 );
|
||||
// ms.SetMetaDown();
|
||||
|
||||
|
||||
return ms;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user