Ignore:
Timestamp:
Feb 13, 2003, 11:34:49 AM (23 years ago)
Author:
sandervl
Message:

Check if WM_KILLFOCUS was already sent by SetFocus(0) call

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/user32/oslibmsgtranslate.cpp

    r9791 r9792  
    1 /* $Id: oslibmsgtranslate.cpp,v 1.100 2003-02-13 10:12:25 sandervl Exp $ */
     1/* $Id: oslibmsgtranslate.cpp,v 1.101 2003-02-13 10:34:48 sandervl Exp $ */
    22/*
    33 * Window message translation functions for OS/2
     
    285285
    286286        if((ULONG)os2Msg->mp2 == TRUE) {
    287                 winMsg->message = WINWM_SETFOCUS;
    288                 winMsg->wParam  = (WPARAM)hwndFocus;
     287            winMsg->message = WINWM_SETFOCUS;
     288            winMsg->wParam  = (WPARAM)hwndFocus;
    289289        }
    290290        else {
     291            //If SetFocus(0) was called, then the window has already received
     292            //a WM_KILLFOCUS; don't send another one
     293            if(!fIgnoreKeystrokes) {
    291294                winMsg->message = WINWM_KILLFOCUS;
    292295                winMsg->wParam  = (WPARAM)hwndFocus;
     296            }
     297            else {
     298                dprintf(("Window has already received a WM_KILLFOCUS (SetFocus(0)); ignore"));
     299                goto dummymessage;
     300            }
    293301        }
    294302        break;
Note: See TracChangeset for help on using the changeset viewer.