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.

77 lines
2.4 KiB

  1. #ifndef __NmChannelAudio_h__
  2. #define __NmChannelAudio_h__
  3. /////////////////////////////////////////////////////////////////////////////
  4. // CNmChannelAudioObj
  5. class ATL_NO_VTABLE CNmChannelAudioObj :
  6. public CComObjectRootEx<CComSingleThreadModel>,
  7. public IConnectionPointContainerImpl<CNmChannelAudioObj>,
  8. public IConnectionPointImpl<CNmChannelAudioObj, &IID_INmChannelNotify, CComDynamicUnkArray>,
  9. public IConnectionPointImpl<CNmChannelAudioObj, &IID_INmChannelAudioNotify, CComDynamicUnkArray>,
  10. public INmChannelAudio,
  11. public INmChannelAudioNotify,
  12. public IInternalChannelObj
  13. {
  14. protected:
  15. bool m_bIsIncoming;
  16. public:
  17. DECLARE_NO_REGISTRY()
  18. DECLARE_NOT_AGGREGATABLE(CNmChannelAudioObj)
  19. BEGIN_COM_MAP(CNmChannelAudioObj)
  20. COM_INTERFACE_ENTRY(INmChannel)
  21. COM_INTERFACE_ENTRY(INmChannelAudio)
  22. COM_INTERFACE_ENTRY(INmChannelNotify)
  23. COM_INTERFACE_ENTRY(INmChannelAudioNotify)
  24. COM_INTERFACE_ENTRY(IInternalChannelObj)
  25. COM_INTERFACE_ENTRY(IConnectionPointContainer)
  26. END_COM_MAP()
  27. BEGIN_CONNECTION_POINT_MAP(CNmChannelAudioObj)
  28. CONNECTION_POINT_ENTRY(IID_INmChannelNotify)
  29. CONNECTION_POINT_ENTRY(IID_INmChannelAudioNotify)
  30. END_CONNECTION_POINT_MAP()
  31. // Construction and destruection
  32. CNmChannelAudioObj();
  33. ~CNmChannelAudioObj();
  34. static HRESULT CreateInstance(CNmConferenceObj* pConfObj, INmChannel** ppChannel, bool bIsIncoming);
  35. // InmChannelAudio methods
  36. STDMETHOD(IsIncoming)(void);
  37. STDMETHOD(GetState)(NM_AUDIO_STATE *puState);
  38. STDMETHOD(GetProperty)(NM_AUDPROP uID,ULONG_PTR *puValue);
  39. STDMETHOD(SetProperty)(NM_AUDPROP uID,ULONG_PTR uValue);
  40. // INmChannelAudioNotify methods
  41. STDMETHOD(StateChanged)(NM_AUDIO_STATE uState);
  42. STDMETHOD(PropertyChanged)(DWORD dwReserved);
  43. // IInternalChannelObj methods
  44. STDMETHOD(GetInternalINmChannel)(INmChannel** ppChannel);
  45. STDMETHOD(ChannelRemoved)();
  46. // Helpers
  47. HRESULT Fire_MemberChanged(NM_MEMBER_NOTIFY uNotify, INmMember *pMember);
  48. HRESULT Fire_StateChanged(NM_AUDIO_STATE uState);
  49. HRESULT Fire_PropertyChanged(DWORD dwReserved);
  50. void _OnActivate(bool bActive) {;}
  51. virtual CNmConferenceObj* GetConfObj() = 0;
  52. virtual void RemoveMembers() = 0;
  53. virtual BOOL GetbActive() = 0;
  54. virtual bool IsChannelValid() = 0;
  55. STDMETHOD(Activate)(BOOL bActive);
  56. HRESULT _IsActive();
  57. HRESULT _SetActive(BOOL bActive);
  58. };
  59. #endif // __NmChannelAudio_h__
  60.