Team Fortress 2 Source Code as on 22/4/2020
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.1 KiB

  1. //========= Copyright Valve Corporation, All rights reserved. ============//
  2. //
  3. // Purpose:
  4. //
  5. // $NoKeywords: $
  6. //=============================================================================//
  7. #ifndef TOOLAXISHANDLE_H
  8. #define TOOLAXISHANDLE_H
  9. #ifdef _WIN32
  10. #pragma once
  11. #endif
  12. #include "ToolInterface.h"
  13. class CMapAxisHandle;
  14. class CMapPointHandle;
  15. class CToolAxisHandle : public CBaseTool
  16. {
  17. public:
  18. CToolAxisHandle(void);
  19. void Attach(CMapAxisHandle *pPoint, int nPointIndex);
  20. //
  21. // CBaseTool implementation.
  22. //
  23. virtual ToolID_t GetToolID(void) { return TOOL_AXIS_HANDLE; }
  24. virtual bool OnLMouseDown2D(CMapView2D *pView, UINT nFlags, const Vector2D &vPoint);
  25. virtual bool OnLMouseUp2D(CMapView2D *pView, UINT nFlags, const Vector2D &vPoint);
  26. virtual bool OnMouseMove2D(CMapView2D *pView, UINT nFlags, const Vector2D &vPoint);
  27. virtual void RenderTool2D(CRender2D *pRender);
  28. //virtual void RenderTool3D(CRender3D *pRender);
  29. private:
  30. CMapAxisHandle *m_pAxis; // The axis we are manipulating.
  31. int m_nPointIndex; // The index of the endpoint we are manipulating [0,1].
  32. };
  33. #endif // TOOLAXISHANDLE_H