Changeset 10136 for trunk/src/user32/window.cpp
- Timestamp:
- Jun 3, 2003, 1:58:57 PM (22 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/user32/window.cpp
r9974 r10136 1 /* $Id: window.cpp,v 1.13 4 2003-04-02 12:58:02sandervl Exp $ */1 /* $Id: window.cpp,v 1.135 2003-06-03 11:58:38 sandervl Exp $ */ 2 2 /* 3 3 * Win32 window apis for OS/2 … … 781 781 782 782 hwnd_O = window->getOS2WindowHandle(); 783 if(teb->o.odin.hwndFocus) { 784 lastFocus = teb->o.odin.hwndFocus; 785 } 786 else lastFocus = OSLibWinQueryFocus (OSLIB_HWND_DESKTOP); 783 lastFocus = OSLibWinQueryFocus (OSLIB_HWND_DESKTOP); 787 784 788 785 hwndTopParent = window->GetTopParent(); … … 806 803 } 807 804 808 //PM doesn't allow SetFocus calls during WM_SETFOCUS message processing;809 //must delay this function call810 if(teb->o.odin.fWM_SETFOCUS) {811 dprintf(("USER32: Delay SetFocus call!"));812 teb->o.odin.hwndFocus = hwnd;813 814 //If keystrokes were ignored and focus is set to the old focus window, then815 //PM won't send us a WM_SETFOCUS message. (as we don't inform PM for SetFocus(0))816 if(fIgnoreKeystrokes && lastFocus_W == hwnd) {817 dprintf(("Manually send WM_SETFOCUS; real focus window hasn't changed"));818 SendMessageA(lastFocus_W, WM_SETFOCUS, 0, 0);819 }820 else {821 //mp1 = win32 window handle822 //mp2 = top parent if activation required823 OSLibPostMessageDirect(hwnd_O, WIN32APP_SETFOCUSMSG, hwnd, (activate) ? hwndTopParent : 0);824 }825 RELEASE_WNDOBJ(window);826 return lastFocus_W;827 }828 teb->o.odin.hwndFocus = 0;829 805 if(!IsWindow(hwnd)) return FALSE; //abort if window destroyed 830 806 … … 839 815 SendMessageA(lastFocus_W, WM_SETFOCUS, 0, 0); 840 816 } 841 842 817 fIgnoreKeystrokes = FALSE; 843 818 return ret; … … 860 835 return 0; 861 836 } 862 //PM doesn't allow SetFocus calls during WM_SETFOCUS message processing;863 //If focus was changed during WM_SETFOCUS, the focus window handle is864 //stored in teb->o.odin.hwndFocus (set back to 0 when delayed SetFocus865 //is activated)866 if(teb->o.odin.hwndFocus) {867 dprintf(("USER32: GetFocus %x (DURING WM_SETFOCUS PROCESSING)", teb->o.odin.hwndFocus));868 return teb->o.odin.hwndFocus;869 }870 871 837 hwnd = OSLibWinQueryFocus(OSLIB_HWND_DESKTOP); 872 838 hwnd = OS2ToWin32Handle(hwnd);
Note:
See TracChangeset
for help on using the changeset viewer.