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.

97 lines
2.6 KiB

  1. #pragma once
  2. #ifndef _ACTIVATOR_H
  3. #define _ACTIVATOR_H
  4. #include <objbase.h>
  5. #include <windows.h>
  6. #include "cstrings.h"
  7. #include "dbglog.h"
  8. // ----------------------------------------------------------------------
  9. class CActivator;
  10. typedef CActivator *LPACTIVATOR;
  11. STDAPI CreateActivator(
  12. LPACTIVATOR *ppActivator,
  13. CDebugLog * pDbgLog,
  14. DWORD dwFlags);
  15. // ----------------------------------------------------------------------
  16. class CActivator : public IAssemblyBindSink//: public IActivator
  17. {
  18. public:
  19. // IUnknown methods
  20. STDMETHODIMP QueryInterface(REFIID riid,void ** ppv);
  21. STDMETHODIMP_(ULONG) AddRef();
  22. STDMETHODIMP_(ULONG) Release();
  23. // IActivator methods
  24. STDMETHOD(Initialize)(
  25. /* in */ LPCWSTR pwzFilePath,
  26. /* in */ LPCWSTR pwzFileURL);
  27. STDMETHOD(Process)();
  28. STDMETHOD(Execute)();
  29. // IAssemblyBindSink methods
  30. STDMETHOD(OnProgress)(
  31. /* in */ DWORD dwNotification,
  32. /* in */ HRESULT hrNotification,
  33. /* in */ LPCWSTR szNotification,
  34. /* in */ DWORD dwProgress,
  35. /* in */ DWORD dwProgressMax,
  36. /* in */ IUnknown *pUnk);
  37. CActivator(CDebugLog * pDbgLog);
  38. ~CActivator();
  39. private:
  40. HRESULT CheckZonePolicy(LPWSTR pwzURL);
  41. HRESULT ResolveAndInstall(LPWSTR *ppwzDesktopManifestPathName);
  42. HRESULT HandlePlatformCheckResult();
  43. DWORD _dwSig;
  44. DWORD _cRef;
  45. DWORD _hr;
  46. LPASSEMBLY_MANIFEST_IMPORT _pManImport;
  47. LPASSEMBLY_IDENTITY _pAsmId;
  48. IManifestInfo *_pAppInfo;
  49. LPASSEMBLY_MANIFEST_EMIT _pManEmit;
  50. HRESULT _hrManEmit;
  51. LPWSTR _pwzAppRootDir;
  52. LPWSTR _pwzAppManifestPath;
  53. LPWSTR _pwzCodebase;
  54. DWORD _dwManifestType;
  55. BOOL _bIs1stTimeInstall;
  56. BOOL _bIsCheckingRequiredUpdate;
  57. CString _sWebManifestURL;
  58. IInternetSecurityManager* _pSecurityMgr;
  59. CDebugLog *_pDbgLog;
  60. LPTPLATFORM_INFO _ptPlatform;
  61. DWORD _dwMissingPlatform;
  62. #ifdef DEVMODE
  63. BOOL _bIsDevMode;
  64. #endif
  65. friend HRESULT CreateActivator(
  66. LPACTIVATOR *ppActivator,
  67. CDebugLog * pDbgLog,
  68. DWORD dwFlags);
  69. };
  70. #endif // _ACTIVATOR_H