m_oldWndProc = 0;
m_useCtl3D = FALSE;
m_mouseInWindow = FALSE;
+ m_lastKeydownProcessed = FALSE;
// wxWnd
m_hMenu = 0;
break;
}
- if ( i == 3 )
- {
- // how did it happen? maybe OnSize() handler does something really
- // strange in this class?
- wxFAIL_MSG( _T("logic error in DoSetClientSize") );
-
- break;
- }
-
int widthClient = width,
heightClient = height;
case WM_SYSKEYDOWN:
case WM_KEYDOWN:
+ m_lastKeydownProcessed = FALSE;
// If this has been processed by an event handler,
// return 0 now (we've handled it).
if ( HandleKeyDown((WORD) wParam, lParam) )
{
processed = TRUE;
-
+ m_lastKeydownProcessed = TRUE;
break;
}
if ( wParam == VK_SHIFT || wParam == VK_CONTROL )
{
processed = TRUE;
-
break;
}
// WM_KEYDOWN one
bool wxWindowMSW::HandleChar(WXWPARAM wParam, WXLPARAM lParam, bool isASCII)
{
+ if (m_lastKeydownProcessed) {
+ // The key was handled in the EVT_KEY_DOWN. Handling a key in an
+ // EVT_KEY_DOWN handler is meant, by design, to prevent EVT_CHARs
+ // from happening, so just bail out at this point.
+ m_lastKeydownProcessed = FALSE;
+ return TRUE;
+ }
+
bool ctrlDown = FALSE;
int id;
{
POINT pt;
GetCursorPos( & pt );
-
+
return wxPoint(pt.x, pt.y);
}