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.

33 lines
1.3 KiB

  1. //===== Copyright © 1996-2007, Valve Corporation, All rights reserved. ======//
  2. //
  3. // Purpose:
  4. //
  5. // $NoKeywords: $
  6. //
  7. //===========================================================================//
  8. #ifndef LOCALFLEXCONTROLLER_H
  9. #define LOCALFLEXCONTROLLER_H
  10. #ifdef _WIN32
  11. #pragma once
  12. #endif
  13. #include "tier0/platform.h"
  14. enum LocalFlexController_t
  15. {
  16. // We cast 0 & -1 into this enum, so we have to define them here to avoid SNC complaining
  17. DUMMY_INVALID_FLEX_CONTROLLER = -1,
  18. DUMMY_NULL_FLEX_CONTROLLER = 0,
  19. // this isn't really an enum - its just a typed int. gcc will not accept it as a fwd decl, so we'll define one value
  20. DUMMY_FLEX_CONTROLLER=0x7fffffff // make take 32 bits
  21. };
  22. inline LocalFlexController_t &operator++( LocalFlexController_t &a ) { return a = LocalFlexController_t( int( a ) + 1 ); }
  23. inline LocalFlexController_t &operator--( LocalFlexController_t &a ) { return a = LocalFlexController_t( int( a ) - 1 ); }
  24. inline LocalFlexController_t operator++( LocalFlexController_t &a, int ) { LocalFlexController_t t = a; a = LocalFlexController_t( int( a ) + 1 ); return t; }
  25. inline LocalFlexController_t operator--( LocalFlexController_t &a, int ) { LocalFlexController_t t = a; a = LocalFlexController_t( int( a ) - 1 ); return t; }
  26. #endif // LOCALFLEXCONTROLLER_H