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.

73 lines
1.6 KiB

  1. //=======================================================================
  2. //
  3. // Copyright (c) 2001 Microsoft Corporation. All Rights Reserved.
  4. //
  5. // File: AUInternals.h
  6. //
  7. // Creator: PeterWi
  8. //
  9. // Purpose: Client AU Internal Definitions
  10. //
  11. //=======================================================================
  12. #pragma once
  13. #include "aubasecatalog.h"
  14. extern AUClientCatalog *gpClientCatalog;
  15. struct AUDownloadStatus
  16. {
  17. DWORD m_percentageComplete;
  18. BOOL m_bSuspended;
  19. };
  20. class CAUInternals
  21. {
  22. public:
  23. CAUInternals():m_pUpdates(NULL)
  24. {}
  25. ~CAUInternals();
  26. HRESULT m_Init()
  27. {
  28. return CoCreateInstance(__uuidof(Updates),
  29. NULL,
  30. CLSCTX_LOCAL_SERVER,
  31. IID_IUpdates,
  32. (LPVOID*)&m_pUpdates);
  33. }
  34. HRESULT m_setReminderTimeout(UINT iTimeout);
  35. HRESULT m_setReminderState(DWORD);
  36. HRESULT m_getServiceState(AUSTATE *pAuState);
  37. HRESULT m_getServiceOption(AUOPTION *pauopt)
  38. {
  39. #ifdef TESTUI
  40. return S_OK;
  41. #else
  42. HRESULT hr = m_pUpdates->get_Option(pauopt);
  43. return hr;
  44. #endif
  45. }
  46. HRESULT m_setServiceOption(AUOPTION auopt)
  47. {
  48. #ifdef TESTUI
  49. return S_OK;
  50. #else
  51. return m_pUpdates->put_Option(auopt);
  52. #endif
  53. }
  54. HRESULT m_getServiceUpdatesList(void);
  55. HRESULT m_saveSelectionsToServer(IUpdates *pUpdates);
  56. HRESULT m_startDownload(void);
  57. HRESULT m_getDownloadStatus(UINT *, DWORD *);
  58. HRESULT m_setDownloadPaused(BOOL);
  59. HRESULT m_startInstall(BOOL fAutoInstall = FALSE);
  60. HRESULT m_configureAU();
  61. HRESULT m_AvailableSessions(LPUINT pcSess);
  62. HRESULT m_getEvtHandles(DWORD dwProcId, AUEVTHANDLES *pAuEvtHandles);
  63. IUpdates* m_pUpdates;
  64. AUCatalogItemList m_ItemList;
  65. };