BsWin32Platform.h 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738
  1. //********************************** Banshee Engine (www.banshee3d.com) **************************************************//
  2. //**************** Copyright (c) 2016 Marko Pintera ([email protected]). All rights reserved. **********************//
  3. #pragma once
  4. #include "Platform/BsPlatform.h"
  5. #define WIN32_LEAN_AND_MEAN
  6. #if !defined(NOMINMAX) && defined(_MSC_VER)
  7. # define NOMINMAX // Required to stop windows.h messing up std::min
  8. #endif
  9. #include <windows.h>
  10. #include <windowsx.h>
  11. #define WM_BS_SETCAPTURE WM_USER + 101
  12. #define WM_BS_RELEASECAPTURE WM_USER + 102
  13. namespace bs
  14. {
  15. /** @addtogroup Platform-Internal
  16. * @{
  17. */
  18. /** Various Win32 specific functionality. Contains the main message loop. */
  19. class BS_CORE_EXPORT Win32Platform : public Platform
  20. {
  21. public:
  22. /** Called when a new DropTarget gets created. */
  23. static void registerDropTarget(DropTarget* target);
  24. /** Called just before a DropTarget gets destroyed. */
  25. static void unregisterDropTarget(DropTarget* target);
  26. /** Main message loop callback that processes messages received from windows. */
  27. static LRESULT CALLBACK _win32WndProc(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam);
  28. };
  29. /** @} */
  30. }