X-Git-Url: https://git.ucc.asn.au/?a=blobdiff_plain;f=Usermode%2FApplications%2Faxwin3_src%2FWM%2Fwm_input.c;h=66088f926e0a74d6b5598faa8a52cc3e8d179c50;hb=a644ed9dc9954091daf616dfe93ab2e2a920bf5d;hp=af258ff14fe1b18269c832d685489f565533e630;hpb=086346323aae470047d375a12104872c899056d6;p=tpg%2Facess2.git diff --git a/Usermode/Applications/axwin3_src/WM/wm_input.c b/Usermode/Applications/axwin3_src/WM/wm_input.c index af258ff1..66088f92 100644 --- a/Usermode/Applications/axwin3_src/WM/wm_input.c +++ b/Usermode/Applications/axwin3_src/WM/wm_input.c @@ -15,8 +15,6 @@ extern tWindow *gpWM_RootWindow; // === GLOBALS === -//! Window which will recieve the next keyboard event -tWindow *gpWM_FocusedWindow; //! Window in which the mouse button was originally pressed tWindow *gpWM_DownStartWindow[MAX_BUTTONS]; @@ -93,7 +91,7 @@ void WM_Input_MouseButton(int X, int Y, int ButtonIndex, int Pressed) if( ButtonIndex == 0 && Pressed == 1 ) { _SysDebug("Gave focus to %p", win); - WM_GiveFocus(win); + WM_FocusWindow(win); WM_RaiseWindow(win); } @@ -112,19 +110,3 @@ void WM_Input_MouseButton(int X, int Y, int ButtonIndex, int Pressed) WM_Input_int_SendBtnMsg(win, X, Y, ButtonIndex, Pressed); } -// --- Manipulation Functions --- -void WM_GiveFocus(tWindow *Destination) -{ - struct sWndMsg_Bool _msg; - - if( gpWM_FocusedWindow == Destination ) - return ; - - _msg.Val = 0; - WM_SendMessage(NULL, gpWM_FocusedWindow, WNDMSG_FOCUS, sizeof(_msg), &_msg); - _msg.Val = 1; - WM_SendMessage(NULL, Destination, WNDMSG_FOCUS, sizeof(_msg), &_msg); - - gpWM_FocusedWindow = Destination; -} -