Fixed windows cursor while being on top panel
This commit is contained in:
parent
599a73ccaf
commit
eda2ad8965
1 changed files with 10 additions and 10 deletions
|
@ -5,12 +5,16 @@
|
|||
//===========================================================================//
|
||||
|
||||
#include "inputsystem.h"
|
||||
#include "dbg.h"
|
||||
#include "key_translation.h"
|
||||
#include "inputsystem/ButtonCode.h"
|
||||
#include "inputsystem/AnalogCode.h"
|
||||
#include "tier0/etwprof.h"
|
||||
#include "tier1/convar.h"
|
||||
#include "tier0/icommandline.h"
|
||||
#include "tier3/tier3.h"
|
||||
#include "vgui/IInput.h"
|
||||
#include <winuser.h>
|
||||
|
||||
#if defined( USE_SDL )
|
||||
#undef M_PI
|
||||
|
@ -289,7 +293,6 @@ static LRESULT CALLBACK InputSystemWindowProc( HWND hwnd, UINT uMsg, WPARAM wPar
|
|||
}
|
||||
#endif
|
||||
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// Hooks input listening up to a window
|
||||
//-----------------------------------------------------------------------------
|
||||
|
@ -606,6 +609,12 @@ void CInputSystem::PollInputState_Windows()
|
|||
// dispatching messages can cause the FPU control word to change
|
||||
SetupFPUControlWord();
|
||||
}
|
||||
|
||||
InputState_t &state = m_InputState[ m_bIsPolling ];
|
||||
|
||||
POINT point;
|
||||
GetCursorPos(&point);
|
||||
UpdateMousePositionState(state, point.x, point.y);
|
||||
}
|
||||
#endif
|
||||
|
||||
|
@ -1424,15 +1433,6 @@ LRESULT CInputSystem::WindowProc( HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lP
|
|||
|
||||
#endif // !USE_SDL
|
||||
|
||||
case WM_MOUSEMOVE:
|
||||
{
|
||||
UpdateMousePositionState( state, (short)LOWORD(lParam), (short)HIWORD(lParam) );
|
||||
|
||||
int nButtonMask = ButtonMaskFromMouseWParam( wParam );
|
||||
UpdateMouseButtonState( nButtonMask );
|
||||
}
|
||||
break;
|
||||
|
||||
}
|
||||
|
||||
#if defined( PLATFORM_WINDOWS_PC ) && !defined( USE_SDL )
|
||||
|
|
Loading…
Reference in a new issue