ifc_skinnedrating.h 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162
  1. #ifndef NULLSOFT_WINAMP_SKINNED_RATING_INTERFACE_HEADER
  2. #define NULLSOFT_WINAMP_SKINNED_RATING_INTERFACE_HEADER
  3. #if defined(_MSC_VER) && (_MSC_VER >= 1020)
  4. #pragma once
  5. #endif
  6. // {9CF4F23F-1F50-4f12-9B0A-A7F129E21AB8}
  7. static const GUID IFC_SkinnedRating =
  8. { 0x9cf4f23f, 0x1f50, 0x4f12, { 0x9b, 0xa, 0xa7, 0xf1, 0x29, 0xe2, 0x1a, 0xb8 } };
  9. #include <bfc/dispatch.h>
  10. class ifc_menucustomizer;
  11. class __declspec(novtable) ifc_skinnedrating : public Dispatchable
  12. {
  13. protected:
  14. ifc_skinnedrating() {}
  15. ~ifc_skinnedrating() {}
  16. public:
  17. HRESULT Draw(HDC hdc, INT maxValue, INT value, INT trackingVal, RECT *prc, UINT fStyle);
  18. HRESULT HitTest(POINT pt, INT maxValue, RECT *prc, UINT fStyle, LONG *result);
  19. HRESULT CalcMinRect(INT maxValue, RECT *prc);
  20. HRESULT CreateMenuCustomizer(HMENU hMenu, ifc_menucustomizer **customizer);
  21. public:
  22. DISPATCH_CODES
  23. {
  24. API_DRAW = 10,
  25. API_HITTEST = 20,
  26. API_CALCMINRECT = 30,
  27. API_CREATEMENUCUSTOMIZER = 40,
  28. };
  29. };
  30. inline HRESULT ifc_skinnedrating::Draw(HDC hdc, INT maxValue, INT value, INT trackingVal, RECT *prc, UINT fStyle)
  31. {
  32. return _call(API_DRAW, (HRESULT)E_NOTIMPL, hdc, maxValue, value, trackingVal, prc, fStyle);
  33. }
  34. inline HRESULT ifc_skinnedrating::HitTest(POINT pt, INT maxValue, RECT *prc, UINT fStyle, LONG *result)
  35. {
  36. return _call(API_HITTEST, (HRESULT)E_NOTIMPL, pt, maxValue, prc, fStyle, result);
  37. }
  38. inline HRESULT ifc_skinnedrating::CalcMinRect(INT maxValue, RECT *prc)
  39. {
  40. return _call(API_CALCMINRECT, (HRESULT)E_NOTIMPL, maxValue, prc);
  41. }
  42. inline HRESULT ifc_skinnedrating::CreateMenuCustomizer(HMENU hMenu, ifc_menucustomizer **customizer)
  43. {
  44. return _call(API_CREATEMENUCUSTOMIZER, (HRESULT)E_NOTIMPL, hMenu, customizer);
  45. }
  46. #endif // NULLSOFT_WINAMP_SKINNED_RATING_INTERFACE_HEADER