Source code of Windows XP (NT5)
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.

139 lines
3.9 KiB

  1. ////////////////////////////////////////////////////////////////////////////////
  2. //
  3. // chanmgri.h
  4. //
  5. // The class definition for the CChannelMgr
  6. //
  7. // History:
  8. //
  9. // 4/30/97 julianj Created.
  10. //
  11. ////////////////////////////////////////////////////////////////////////////////
  12. //
  13. // Check for previous includes of this file.
  14. //
  15. #ifndef _CHANMGRI_H_
  16. #define _CHANMGRI_H_
  17. //
  18. // The class definition for the Channel Manager
  19. //
  20. class CChannelMgr : public IChannelMgr,
  21. public IChannelMgrPriv2,
  22. #ifdef UNICODE
  23. public ICopyHookA,
  24. #endif
  25. public ICopyHook
  26. {
  27. //
  28. // Methods
  29. //
  30. public:
  31. //
  32. // Constructor
  33. //
  34. CChannelMgr(void);
  35. //
  36. // IUnknown
  37. //
  38. STDMETHODIMP QueryInterface(REFIID, void **);
  39. STDMETHODIMP_(ULONG) AddRef(void);
  40. STDMETHODIMP_(ULONG) Release(void);
  41. //
  42. // IChannelMgr methods
  43. //
  44. STDMETHODIMP AddChannelShortcut(CHANNELSHORTCUTINFO *pChannelInfo);
  45. STDMETHODIMP DeleteChannelShortcut(BSTR strTitle);
  46. STDMETHODIMP AddCategory(CHANNELCATEGORYINFO *pCategoryInfo);
  47. STDMETHODIMP DeleteCategory(BSTR strTitle);
  48. STDMETHODIMP EnumChannels(DWORD dwEnumFlags, LPCWSTR pszURL,
  49. IEnumChannels** pIEnumChannels);
  50. //
  51. // IChannelMgrPrive methods.
  52. //
  53. STDMETHODIMP GetBaseChannelPath(LPSTR pszPath, int cch);
  54. STDMETHODIMP InvalidateCdfCache(void);
  55. STDMETHODIMP PreUpdateChannelImage(LPCSTR pszPath,
  56. LPSTR pszHashItem,
  57. int* piIndex,
  58. UINT* puFlags,
  59. int* piImageIndex);
  60. STDMETHODIMP UpdateChannelImage(LPCWSTR pszHashItem,
  61. int iIndex,
  62. UINT uFlags,
  63. int iImageIndex);
  64. STDMETHODIMP GetChannelFolderPath (LPSTR pszPath, int cch,
  65. enum _tagCHANNELFOLDERLOCATION chLoc);
  66. STDMETHODIMP GetChannelFolder (LPITEMIDLIST* ppidl,
  67. enum _tagCHANNELFOLDERLOCATION chLoc);
  68. STDMETHODIMP DownloadMinCDF(HWND hwnd, LPCWSTR pwszURL, LPWSTR pwszTitle,
  69. DWORD cchTitle, SUBSCRIPTIONINFO *pSubInfo,
  70. BOOL *pfIsSoftware);
  71. STDMETHODIMP ShowChannel(IWebBrowser2 *pWebBrowser2, LPWSTR pwszURL, HWND hwnd);
  72. STDMETHODIMP IsChannelInstalled(LPCWSTR pwszURL);
  73. STDMETHODIMP IsChannelPreinstalled(LPCWSTR pwszURL, BSTR * bstrFile);
  74. STDMETHODIMP RemovePreinstalledMapping(LPCWSTR pwszURL);
  75. STDMETHODIMP SetupPreinstalledMapping(LPCWSTR pwszURL, LPCWSTR pwszFile);
  76. STDMETHODIMP AddAndSubscribe(HWND hwnd, LPCWSTR pwszURL,
  77. ISubscriptionMgr *pSubscriptionMgr);
  78. STDMETHODIMP WriteScreenSaverURL(LPCWSTR pwszURL, LPCWSTR pwszScreenSaverURL);
  79. STDMETHODIMP RefreshScreenSaverURLs();
  80. //
  81. // ICopyHook method
  82. //
  83. STDMETHODIMP_(UINT) CopyCallback(
  84. HWND hwnd,
  85. UINT wFunc,
  86. UINT wFlags,
  87. LPCTSTR pszSrcFile,
  88. DWORD dwSrcAttribs,
  89. LPCTSTR pszDestFile,
  90. DWORD dwDestAttribs
  91. );
  92. #ifdef UNICODE
  93. STDMETHODIMP_(UINT) CopyCallback(
  94. HWND hwnd,
  95. UINT wFunc,
  96. UINT wFlags,
  97. LPCSTR pszSrcFile,
  98. DWORD dwSrcAttribs,
  99. LPCSTR pszDestFile,
  100. DWORD dwDestAttribs
  101. );
  102. #endif
  103. // Helpers
  104. STDMETHODIMP AddAndSubscribeEx2(HWND hwnd, LPCWSTR pwszURL,
  105. ISubscriptionMgr *pSubscriptionMgr,
  106. BOOL bAlwaysSubscribe);
  107. private:
  108. //
  109. // Destructor
  110. //
  111. ~CChannelMgr(void);
  112. //
  113. // Member variables.
  114. //
  115. private:
  116. ULONG m_cRef;
  117. };
  118. #endif // _CHANMGRI_H_