1
0

oswndhost.h 1.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. #ifndef __OSWNDHOST_H
  2. #define __OSWNDHOST_H
  3. #include <bfc/dispatch.h>
  4. // {7050AACF-2731-4319-AF32-4ECE4CC8BDC4}
  5. static const GUID osWndHostGuid =
  6. { 0x7050aacf, 0x2731, 0x4319, { 0xaf, 0x32, 0x4e, 0xce, 0x4c, 0xc8, 0xbd, 0xc4 } };
  7. class OSWndHost : public Dispatchable
  8. {
  9. public:
  10. void oswndhost_host(HWND oswnd);
  11. void oswndhost_unhost();
  12. void oswndhost_setRegionOffsets(RECT *r);
  13. DISPATCH_CODES
  14. {
  15. OSWNDHOST_OSWNDHOST_HOST = 0,
  16. OSWNDHOST_OSWNDHOST_UNHOST = 5,
  17. OSWNDHOST_OSWNDHOST_SETREGIONOFFSETS = 10,
  18. };
  19. };
  20. inline void OSWndHost::oswndhost_host(HWND oswnd)
  21. {
  22. _voidcall(OSWNDHOST_OSWNDHOST_HOST, oswnd);
  23. }
  24. inline void OSWndHost::oswndhost_unhost()
  25. {
  26. _voidcall(OSWNDHOST_OSWNDHOST_UNHOST);
  27. }
  28. inline void OSWndHost::oswndhost_setRegionOffsets(RECT *r)
  29. {
  30. _voidcall(OSWNDHOST_OSWNDHOST_SETREGIONOFFSETS, r);
  31. }
  32. class OSWndHostI : public OSWndHost
  33. {
  34. public:
  35. virtual void oswndhost_host(HWND oswnd) = 0;
  36. virtual void oswndhost_unhost() = 0;
  37. virtual void oswndhost_setRegionOffsets(RECT *r) = 0;
  38. protected:
  39. RECVS_DISPATCH;
  40. };
  41. #endif