Counter Strike : Global Offensive Source Code
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

47 lines
1.6 KiB

  1. //===== Copyright � 1996-2005, Valve Corporation, All rights reserved. ======//
  2. //
  3. // Purpose: Methods related to input
  4. //
  5. // $Revision: $
  6. // $NoKeywords: $
  7. //===========================================================================//
  8. #ifndef INPUT_H
  9. #define INPUT_H
  10. #ifdef _WIN32
  11. #pragma once
  12. #endif
  13. struct InputEvent_t;
  14. FORWARD_DECLARE_HANDLE( InputContextHandle_t );
  15. //-----------------------------------------------------------------------------
  16. // Initializes the input system
  17. //-----------------------------------------------------------------------------
  18. void InitInput();
  19. //-----------------------------------------------------------------------------
  20. // Hooks input listening up to a window
  21. //-----------------------------------------------------------------------------
  22. void InputAttachToWindow(void *hwnd);
  23. void InputDetachFromWindow(void *hwnd);
  24. // If input isn't hooked, this forwards messages to vgui.
  25. void InputHandleWindowMessage( void *hwnd, unsigned int uMsg, unsigned int wParam, long lParam );
  26. //-----------------------------------------------------------------------------
  27. // Handles an input event, returns true if the event should be filtered
  28. // from the rest of the game
  29. //-----------------------------------------------------------------------------
  30. bool InputHandleInputEvent( InputContextHandle_t hContext, const InputEvent_t &event );
  31. //-----------------------------------------------------------------------------
  32. // Enables/disables input (enabled by default)
  33. //-----------------------------------------------------------------------------
  34. void EnableInput( bool bEnable );
  35. #endif // INPUT_H