ifc_devicecommand.h 1.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. #ifndef _NULLSOFT_WINAMP_DEVICES_DEVICE_COMMAND_INTERFACE_HEADER
  2. #define _NULLSOFT_WINAMP_DEVICES_DEVICE_COMMAND_INTERFACE_HEADER
  3. #if defined(_MSC_VER) && (_MSC_VER >= 1020)
  4. #pragma once
  5. #endif
  6. #include <bfc/platform/guid.h>
  7. // {52C5C581-65DC-435e-AEFA-1616CB81B283}
  8. static const GUID IFC_DeviceCommand =
  9. { 0x52c5c581, 0x65dc, 0x435e, { 0xae, 0xfa, 0x16, 0x16, 0xcb, 0x81, 0xb2, 0x83 } };
  10. #include "ifc_deviceobject.h"
  11. typedef enum DeviceCommandFlags
  12. {
  13. DeviceCommandFlag_None = 0,
  14. DeviceCommandFlag_Primary = (1 << 0),
  15. DeviceCommandFlag_Disabled = (1 << 1),
  16. DeviceCommandFlag_Active = (1 << 2),
  17. DeviceCommandFlag_Hidden = (1 << 3),
  18. DeviceCommandFlag_Group = (1 << 4),
  19. }DeviceCommandFlags;
  20. DEFINE_ENUM_FLAG_OPERATORS(DeviceCommandFlags);
  21. typedef enum DeviceCommandContext
  22. {
  23. DeviceCommandContext_Unknown = 0,
  24. DeviceCommandContext_NavigationMenu = 1,
  25. DeviceCommandContext_ViewMenu = 2,
  26. DeviceCommandContext_View = 3,
  27. } DeviceCommandContext;
  28. class __declspec(novtable) ifc_devicecommand : public ifc_deviceobject
  29. {
  30. protected:
  31. ifc_devicecommand() {}
  32. ~ifc_devicecommand() {}
  33. public:
  34. HRESULT GetDescription(wchar_t *buffer, size_t bufferSize);
  35. public:
  36. DISPATCH_CODES
  37. {
  38. API_GETDESCRIPTION = 10,
  39. };
  40. };
  41. inline HRESULT ifc_devicecommand::GetDescription(wchar_t *buffer, size_t bufferSize)
  42. {
  43. return _call(API_GETDESCRIPTION, (HRESULT)E_NOTIMPL, buffer, bufferSize);
  44. }
  45. #endif //_NULLSOFT_WINAMP_DEVICES_DEVICE_COMMAND_INTERFACE_HEADER