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.

148 lines
3.4 KiB

  1. #pragma once
  2. #ifndef _MIME_DLL_H
  3. #define _MIME_DLL_H
  4. #include <objbase.h>
  5. #include <windows.h>
  6. #include <oleidl.h>
  7. #include <objsafe.h>
  8. #include <fusenetincludes.h>
  9. // Clases and interfaces
  10. class CActiveXMimeClassFactory: public IClassFactory
  11. {
  12. public:
  13. CActiveXMimeClassFactory ();
  14. // IUnknown Methods
  15. STDMETHOD_ (ULONG, AddRef) ();
  16. STDMETHOD_ (ULONG, Release) ();
  17. STDMETHOD (QueryInterface) (REFIID, void **);
  18. // IClassFactory Moethods
  19. STDMETHOD (LockServer) (BOOL);
  20. STDMETHOD (CreateInstance) (IUnknown*,REFIID,void**);
  21. protected:
  22. long _cRef;
  23. HRESULT _hr;
  24. };
  25. class CActiveXMimePlayer : public IOleObject, public IObjectSafety
  26. {
  27. public:
  28. CActiveXMimePlayer ();
  29. ~CActiveXMimePlayer ();
  30. // IUnknown methods
  31. STDMETHOD_ (ULONG, AddRef) ();
  32. STDMETHOD_ (ULONG, Release) ();
  33. STDMETHOD (QueryInterface) (REFIID, void **);
  34. // IOleObject methods
  35. STDMETHOD (SetClientSite) (
  36. IOleClientSite *pClientSite);
  37. STDMETHOD (GetClientSite) (
  38. IOleClientSite **ppClientSite);
  39. STDMETHOD (SetHostNames) (
  40. LPCOLESTR szContainerApp,
  41. LPCOLESTR szContainerObj);
  42. STDMETHOD (Close) (
  43. DWORD dwSaveOption);
  44. STDMETHOD (SetMoniker) (
  45. DWORD dwWhichMoniker,
  46. IMoniker *pmk);
  47. STDMETHOD (GetMoniker) (
  48. DWORD dwAssign,
  49. DWORD dwWhichMoniker,
  50. IMoniker **ppmk);
  51. STDMETHOD (InitFromData) (
  52. IDataObject *pDataObject,
  53. BOOL fCreation,
  54. DWORD dwReserved);
  55. STDMETHOD (GetClipboardData) (
  56. DWORD dwReserved,
  57. IDataObject **ppDataObject);
  58. STDMETHOD (DoVerb) (
  59. LONG iVerb,
  60. LPMSG lpmsg,
  61. IOleClientSite *pActiveSite,
  62. LONG lindex,
  63. HWND hwndParent,
  64. LPCRECT lprcPosRect);
  65. STDMETHOD (EnumVerbs) (
  66. IEnumOLEVERB **ppEnumOleVerb);
  67. STDMETHOD (Update) ( void);
  68. STDMETHOD (IsUpToDate) ( void);
  69. STDMETHOD (GetUserClassID) (
  70. CLSID *pClsid);
  71. STDMETHOD (GetUserType) (
  72. DWORD dwFormOfType,
  73. LPOLESTR *pszUserType);
  74. STDMETHOD (SetExtent) (
  75. DWORD dwDrawAspect,
  76. SIZEL *psizel);
  77. STDMETHOD (GetExtent) (
  78. DWORD dwDrawAspect,
  79. SIZEL *psizel);
  80. STDMETHOD (Advise) (
  81. IAdviseSink *pAdvSink,
  82. DWORD *pdwConnection);
  83. STDMETHOD (Unadvise) (
  84. DWORD dwConnection);
  85. STDMETHOD (EnumAdvise) (
  86. IEnumSTATDATA **ppenumAdvise);
  87. STDMETHOD (GetMiscStatus) (
  88. DWORD dwAspect,
  89. DWORD *pdwStatus);
  90. STDMETHOD (SetColorScheme) (
  91. LOGPALETTE *pLogpal);
  92. // IOjbectSafety methods
  93. STDMETHOD (GetInterfaceSafetyOptions) (
  94. REFIID riid,
  95. DWORD* pdwSupportedOptions,
  96. DWORD* pdwEnabledOptions);
  97. STDMETHOD (SetInterfaceSafetyOptions) (
  98. REFIID riid,
  99. DWORD dwOptionSetMask,
  100. DWORD dwEnabledOptions);
  101. protected:
  102. HRESULT StartManifestHandler(CString& sURL);
  103. HRESULT DownloadInternetFile(CString& sUrl, LPCWSTR pwzPath);
  104. long _cRef;
  105. HRESULT _hr;
  106. CString _sURL;
  107. CString _sTempFile;
  108. };
  109. extern const GUID CLSID_ActiveXMimePlayer;
  110. #endif // _MIME_DLL_H