Leaked source code of windows server 2003
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.

48 lines
848 B

  1. /*
  2. * Proxy
  3. */
  4. #ifndef DUI_CORE_PROXY_H_INCLUDED
  5. #define DUI_CORE_PROXY_H_INCLUDED
  6. #pragma once
  7. namespace DirectUI
  8. {
  9. ////////////////////////////////////////////////////////
  10. // Proxy message
  11. #define GM_PROXYINVOKE GM_USER
  12. BEGIN_STRUCT(GMSG_PROXYINVOKE, EventMsg)
  13. UINT nType;
  14. void* pData;
  15. END_STRUCT(GMSG_PROXYINVOKE)
  16. ////////////////////////////////////////////////////////
  17. // Proxy
  18. class Proxy
  19. {
  20. public:
  21. Proxy();
  22. ~Proxy();
  23. static HRESULT CALLBACK SyncCallback(HGADGET hgadCur, void * pvCur, EventMsg * pGMsg);
  24. protected:
  25. // Caller invoke
  26. void Invoke(UINT nType, void* pData);
  27. // Callee thread-safe invoke sink
  28. virtual void OnInvoke(UINT nType, void* pData);
  29. HGADGET _hgSync;
  30. };
  31. } // namespace DirectUI
  32. #endif // DUI_CORE_PROXY_H_INCLUDED