CmOSCursorImpl.h 599 B

123456789101112131415161718192021222324252627282930313233
  1. #pragma once
  2. #include "CmPrerequisitesUtil.h"
  3. #include "CmInt2.h"
  4. #include <X11/X.h>
  5. #include <X11/Xlib.h>
  6. #include <X11/Xutil.h>
  7. namespace CamelotEngine
  8. {
  9. /**
  10. * @brief Provides controls for operating system cursor.
  11. */
  12. class CM_UTILITY_EXPORT OSCursor
  13. {
  14. public:
  15. OSCursor();
  16. static Int2 getPosition();
  17. static void setPosition(const Int2& pos);
  18. static void hide();
  19. static void show();
  20. private:
  21. Window mWindow; // TODO - This isn't being set anywhere yet
  22. Cursor mCursor;
  23. Display* mDisplay;
  24. bool mCursorGrabbed;
  25. bool mCursorHidden;
  26. };
  27. }