diff options
Diffstat (limited to 'src/api/burn/balutil/inc')
-rw-r--r-- | src/api/burn/balutil/inc/BAFunctions.h | 12 | ||||
-rw-r--r-- | src/api/burn/balutil/inc/BalBaseBAFunctions.h | 66 | ||||
-rw-r--r-- | src/api/burn/balutil/inc/BalBaseBAFunctionsProc.h | 180 | ||||
-rw-r--r-- | src/api/burn/balutil/inc/BalBaseBootstrapperApplication.h | 90 | ||||
-rw-r--r-- | src/api/burn/balutil/inc/BalBaseBootstrapperApplicationProc.h | 1045 | ||||
-rw-r--r-- | src/api/burn/balutil/inc/BalBootstrapperEngine.h | 17 | ||||
-rw-r--r-- | src/api/burn/balutil/inc/IBAFunctions.h | 2 | ||||
-rw-r--r-- | src/api/burn/balutil/inc/IBootstrapperApplication.h | 29 | ||||
-rw-r--r-- | src/api/burn/balutil/inc/IBootstrapperApplicationFactory.h | 13 | ||||
-rw-r--r-- | src/api/burn/balutil/inc/IBootstrapperEngine.h | 11 | ||||
-rw-r--r-- | src/api/burn/balutil/inc/balinfo.h | 1 | ||||
-rw-r--r-- | src/api/burn/balutil/inc/balutil.h | 30 |
12 files changed, 121 insertions, 1375 deletions
diff --git a/src/api/burn/balutil/inc/BAFunctions.h b/src/api/burn/balutil/inc/BAFunctions.h index 4a0b8599..7908a74c 100644 --- a/src/api/burn/balutil/inc/BAFunctions.h +++ b/src/api/burn/balutil/inc/BAFunctions.h | |||
@@ -1,6 +1,7 @@ | |||
1 | #pragma once | 1 | #pragma once |
2 | // Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. | 2 | // Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. |
3 | 3 | ||
4 | #include "IBootstrapperEngine.h" | ||
4 | 5 | ||
5 | #ifdef __cplusplus | 6 | #ifdef __cplusplus |
6 | extern "C" { | 7 | extern "C" { |
@@ -9,12 +10,14 @@ extern "C" { | |||
9 | // The first 1024 messages are reserved so that the BA messages have the same value here. | 10 | // The first 1024 messages are reserved so that the BA messages have the same value here. |
10 | enum BA_FUNCTIONS_MESSAGE | 11 | enum BA_FUNCTIONS_MESSAGE |
11 | { | 12 | { |
13 | BA_FUNCTIONS_MESSAGE_ONCREATE = BOOTSTRAPPER_APPLICATION_MESSAGE_ONCREATE, | ||
14 | BA_FUNCTIONS_MESSAGE_ONDESTROY = BOOTSTRAPPER_APPLICATION_MESSAGE_ONDESTROY, | ||
15 | BA_FUNCTIONS_MESSAGE_ONSTARTUP = BOOTSTRAPPER_APPLICATION_MESSAGE_ONSTARTUP, | ||
16 | BA_FUNCTIONS_MESSAGE_ONSHUTDOWN = BOOTSTRAPPER_APPLICATION_MESSAGE_ONSHUTDOWN, | ||
12 | BA_FUNCTIONS_MESSAGE_ONDETECTBEGIN = BOOTSTRAPPER_APPLICATION_MESSAGE_ONDETECTBEGIN, | 17 | BA_FUNCTIONS_MESSAGE_ONDETECTBEGIN = BOOTSTRAPPER_APPLICATION_MESSAGE_ONDETECTBEGIN, |
13 | BA_FUNCTIONS_MESSAGE_ONDETECTCOMPLETE = BOOTSTRAPPER_APPLICATION_MESSAGE_ONDETECTCOMPLETE, | 18 | BA_FUNCTIONS_MESSAGE_ONDETECTCOMPLETE = BOOTSTRAPPER_APPLICATION_MESSAGE_ONDETECTCOMPLETE, |
14 | BA_FUNCTIONS_MESSAGE_ONPLANBEGIN = BOOTSTRAPPER_APPLICATION_MESSAGE_ONPLANBEGIN, | 19 | BA_FUNCTIONS_MESSAGE_ONPLANBEGIN = BOOTSTRAPPER_APPLICATION_MESSAGE_ONPLANBEGIN, |
15 | BA_FUNCTIONS_MESSAGE_ONPLANCOMPLETE = BOOTSTRAPPER_APPLICATION_MESSAGE_ONPLANCOMPLETE, | 20 | BA_FUNCTIONS_MESSAGE_ONPLANCOMPLETE = BOOTSTRAPPER_APPLICATION_MESSAGE_ONPLANCOMPLETE, |
16 | BA_FUNCTIONS_MESSAGE_ONSTARTUP = BOOTSTRAPPER_APPLICATION_MESSAGE_ONSTARTUP, | ||
17 | BA_FUNCTIONS_MESSAGE_ONSHUTDOWN = BOOTSTRAPPER_APPLICATION_MESSAGE_ONSHUTDOWN, | ||
18 | BA_FUNCTIONS_MESSAGE_ONDETECTFORWARDCOMPATIBLEBUNDLE = BOOTSTRAPPER_APPLICATION_MESSAGE_ONDETECTFORWARDCOMPATIBLEBUNDLE, | 21 | BA_FUNCTIONS_MESSAGE_ONDETECTFORWARDCOMPATIBLEBUNDLE = BOOTSTRAPPER_APPLICATION_MESSAGE_ONDETECTFORWARDCOMPATIBLEBUNDLE, |
19 | BA_FUNCTIONS_MESSAGE_ONDETECTUPDATEBEGIN = BOOTSTRAPPER_APPLICATION_MESSAGE_ONDETECTUPDATEBEGIN, | 22 | BA_FUNCTIONS_MESSAGE_ONDETECTUPDATEBEGIN = BOOTSTRAPPER_APPLICATION_MESSAGE_ONDETECTUPDATEBEGIN, |
20 | BA_FUNCTIONS_MESSAGE_ONDETECTUPDATE = BOOTSTRAPPER_APPLICATION_MESSAGE_ONDETECTUPDATE, | 23 | BA_FUNCTIONS_MESSAGE_ONDETECTUPDATE = BOOTSTRAPPER_APPLICATION_MESSAGE_ONDETECTUPDATE, |
@@ -81,8 +84,6 @@ enum BA_FUNCTIONS_MESSAGE | |||
81 | BA_FUNCTIONS_MESSAGE_ONCACHEPAYLOADEXTRACTCOMPLETE = BOOTSTRAPPER_APPLICATION_MESSAGE_ONCACHEPAYLOADEXTRACTCOMPLETE, | 84 | BA_FUNCTIONS_MESSAGE_ONCACHEPAYLOADEXTRACTCOMPLETE = BOOTSTRAPPER_APPLICATION_MESSAGE_ONCACHEPAYLOADEXTRACTCOMPLETE, |
82 | BA_FUNCTIONS_MESSAGE_ONCACHEPAYLOADEXTRACTPROGRESS = BOOTSTRAPPER_APPLICATION_MESSAGE_ONCACHEPAYLOADEXTRACTPROGRESS, | 85 | BA_FUNCTIONS_MESSAGE_ONCACHEPAYLOADEXTRACTPROGRESS = BOOTSTRAPPER_APPLICATION_MESSAGE_ONCACHEPAYLOADEXTRACTPROGRESS, |
83 | BA_FUNCTIONS_MESSAGE_ONPLANROLLBACKBOUNDARY = BOOTSTRAPPER_APPLICATION_MESSAGE_ONPLANROLLBACKBOUNDARY, | 86 | BA_FUNCTIONS_MESSAGE_ONPLANROLLBACKBOUNDARY = BOOTSTRAPPER_APPLICATION_MESSAGE_ONPLANROLLBACKBOUNDARY, |
84 | BA_FUNCTIONS_MESSAGE_ONSETUPDATEBEGIN = BOOTSTRAPPER_APPLICATION_MESSAGE_ONSETUPDATEBEGIN, | ||
85 | BA_FUNCTIONS_MESSAGE_ONSETUPDATECOMPLETE = BOOTSTRAPPER_APPLICATION_MESSAGE_ONSETUPDATECOMPLETE, | ||
86 | BA_FUNCTIONS_MESSAGE_ONDETECTCOMPATIBLEMSIPACKAGE = BOOTSTRAPPER_APPLICATION_MESSAGE_ONDETECTCOMPATIBLEMSIPACKAGE, | 87 | BA_FUNCTIONS_MESSAGE_ONDETECTCOMPATIBLEMSIPACKAGE = BOOTSTRAPPER_APPLICATION_MESSAGE_ONDETECTCOMPATIBLEMSIPACKAGE, |
87 | BA_FUNCTIONS_MESSAGE_ONPLANCOMPATIBLEMSIPACKAGEBEGIN = BOOTSTRAPPER_APPLICATION_MESSAGE_ONPLANCOMPATIBLEMSIPACKAGEBEGIN, | 88 | BA_FUNCTIONS_MESSAGE_ONPLANCOMPATIBLEMSIPACKAGEBEGIN = BOOTSTRAPPER_APPLICATION_MESSAGE_ONPLANCOMPATIBLEMSIPACKAGEBEGIN, |
88 | BA_FUNCTIONS_MESSAGE_ONPLANCOMPATIBLEMSIPACKAGECOMPLETE = BOOTSTRAPPER_APPLICATION_MESSAGE_ONPLANCOMPATIBLEMSIPACKAGECOMPLETE, | 89 | BA_FUNCTIONS_MESSAGE_ONPLANCOMPATIBLEMSIPACKAGECOMPLETE = BOOTSTRAPPER_APPLICATION_MESSAGE_ONPLANCOMPATIBLEMSIPACKAGECOMPLETE, |
@@ -117,7 +118,8 @@ struct BA_FUNCTIONS_CREATE_ARGS | |||
117 | { | 118 | { |
118 | DWORD cbSize; | 119 | DWORD cbSize; |
119 | DWORD64 qwBAFunctionsAPIVersion; | 120 | DWORD64 qwBAFunctionsAPIVersion; |
120 | BOOTSTRAPPER_CREATE_ARGS* pBootstrapperCreateArgs; | 121 | IBootstrapperEngine* pEngine; |
122 | BOOTSTRAPPER_COMMAND* pCommand; | ||
121 | }; | 123 | }; |
122 | 124 | ||
123 | struct BA_FUNCTIONS_CREATE_RESULTS | 125 | struct BA_FUNCTIONS_CREATE_RESULTS |
diff --git a/src/api/burn/balutil/inc/BalBaseBAFunctions.h b/src/api/burn/balutil/inc/BalBaseBAFunctions.h index 6ad109c3..33b71324 100644 --- a/src/api/burn/balutil/inc/BalBaseBAFunctions.h +++ b/src/api/burn/balutil/inc/BalBaseBAFunctions.h | |||
@@ -1,16 +1,12 @@ | |||
1 | #pragma once | 1 | #pragma once |
2 | // Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. | 2 | // Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. |
3 | 3 | ||
4 | |||
5 | #include <windows.h> | 4 | #include <windows.h> |
6 | #include <msiquery.h> | 5 | #include <msiquery.h> |
7 | 6 | ||
8 | #include "BAFunctions.h" | 7 | #include <batypes.h> |
8 | |||
9 | #include "IBAFunctions.h" | 9 | #include "IBAFunctions.h" |
10 | #include "BootstrapperEngine.h" | ||
11 | #include "BootstrapperApplication.h" | ||
12 | #include "IBootstrapperEngine.h" | ||
13 | #include "IBootstrapperApplication.h" | ||
14 | 10 | ||
15 | class CBalBaseBAFunctions : public IBAFunctions | 11 | class CBalBaseBAFunctions : public IBAFunctions |
16 | { | 12 | { |
@@ -69,8 +65,7 @@ public: // IBootstrapperApplication | |||
69 | virtual STDMETHODIMP_(HRESULT) BAProc( | 65 | virtual STDMETHODIMP_(HRESULT) BAProc( |
70 | __in BOOTSTRAPPER_APPLICATION_MESSAGE /*message*/, | 66 | __in BOOTSTRAPPER_APPLICATION_MESSAGE /*message*/, |
71 | __in const LPVOID /*pvArgs*/, | 67 | __in const LPVOID /*pvArgs*/, |
72 | __inout LPVOID /*pvResults*/, | 68 | __inout LPVOID /*pvResults*/ |
73 | __in_opt LPVOID /*pvContext*/ | ||
74 | ) | 69 | ) |
75 | { | 70 | { |
76 | return E_NOTIMPL; | 71 | return E_NOTIMPL; |
@@ -80,12 +75,31 @@ public: // IBootstrapperApplication | |||
80 | __in BOOTSTRAPPER_APPLICATION_MESSAGE /*message*/, | 75 | __in BOOTSTRAPPER_APPLICATION_MESSAGE /*message*/, |
81 | __in const LPVOID /*pvArgs*/, | 76 | __in const LPVOID /*pvArgs*/, |
82 | __inout LPVOID /*pvResults*/, | 77 | __inout LPVOID /*pvResults*/, |
83 | __inout HRESULT* /*phr*/, | 78 | __inout HRESULT* /*phr*/ |
84 | __in_opt LPVOID /*pvContext*/ | ||
85 | ) | 79 | ) |
86 | { | 80 | { |
87 | } | 81 | } |
88 | 82 | ||
83 | virtual STDMETHODIMP OnCreate( | ||
84 | __in IBootstrapperEngine* pEngine, | ||
85 | __in BOOTSTRAPPER_COMMAND* /*pCommand*/ | ||
86 | ) | ||
87 | { | ||
88 | HRESULT hr = S_OK; | ||
89 | |||
90 | pEngine->AddRef(); | ||
91 | m_pEngine = pEngine; | ||
92 | |||
93 | return hr; | ||
94 | } | ||
95 | |||
96 | virtual STDMETHODIMP OnDestroy( | ||
97 | __in BOOL /*fReload*/ | ||
98 | ) | ||
99 | { | ||
100 | return S_OK; | ||
101 | } | ||
102 | |||
89 | virtual STDMETHODIMP OnStartup() | 103 | virtual STDMETHODIMP OnStartup() |
90 | { | 104 | { |
91 | return S_OK; | 105 | return S_OK; |
@@ -837,20 +851,6 @@ public: // IBootstrapperApplication | |||
837 | return S_OK; | 851 | return S_OK; |
838 | } | 852 | } |
839 | 853 | ||
840 | virtual STDMETHODIMP OnSetUpdateBegin() | ||
841 | { | ||
842 | return S_OK; | ||
843 | } | ||
844 | |||
845 | virtual STDMETHODIMP OnSetUpdateComplete( | ||
846 | __in HRESULT /*hrStatus*/, | ||
847 | __in_z_opt LPCWSTR /*wzPreviousPackageId*/, | ||
848 | __in_z_opt LPCWSTR /*wzNewPackageId*/ | ||
849 | ) | ||
850 | { | ||
851 | return S_OK; | ||
852 | } | ||
853 | |||
854 | virtual STDMETHODIMP OnPlanRestoreRelatedBundle( | 854 | virtual STDMETHODIMP OnPlanRestoreRelatedBundle( |
855 | __in_z LPCWSTR /*wzBundleId*/, | 855 | __in_z LPCWSTR /*wzBundleId*/, |
856 | __in BOOTSTRAPPER_REQUEST_STATE /*recommendedState*/, | 856 | __in BOOTSTRAPPER_REQUEST_STATE /*recommendedState*/, |
@@ -996,22 +996,13 @@ public: // IBAFunctions | |||
996 | } | 996 | } |
997 | 997 | ||
998 | protected: | 998 | protected: |
999 | CBalBaseBAFunctions( | 999 | CBalBaseBAFunctions(HMODULE hModule) |
1000 | __in HMODULE hModule, | ||
1001 | __in IBootstrapperEngine* pEngine, | ||
1002 | __in const BA_FUNCTIONS_CREATE_ARGS* pArgs | ||
1003 | ) | ||
1004 | { | 1000 | { |
1005 | m_cReferences = 1; | 1001 | m_cReferences = 1; |
1006 | m_hModule = hModule; | 1002 | m_hModule = hModule; |
1007 | pEngine->AddRef(); | ||
1008 | m_pEngine = pEngine; | ||
1009 | 1003 | ||
1010 | memcpy_s(&m_command, sizeof(m_command), pArgs->pBootstrapperCreateArgs->pCommand, sizeof(BOOTSTRAPPER_COMMAND)); | 1004 | m_hwndParent = NULL; |
1011 | memcpy_s(&m_baCreateArgs, sizeof(m_baCreateArgs), pArgs->pBootstrapperCreateArgs, sizeof(BOOTSTRAPPER_CREATE_ARGS)); | 1005 | m_pEngine = NULL; |
1012 | memcpy_s(&m_bafCreateArgs, sizeof(m_bafCreateArgs), pArgs, sizeof(BA_FUNCTIONS_CREATE_ARGS)); | ||
1013 | m_baCreateArgs.pCommand = &m_command; | ||
1014 | m_bafCreateArgs.pBootstrapperCreateArgs = &m_baCreateArgs; | ||
1015 | } | 1006 | } |
1016 | 1007 | ||
1017 | virtual ~CBalBaseBAFunctions() | 1008 | virtual ~CBalBaseBAFunctions() |
@@ -1025,8 +1016,5 @@ private: | |||
1025 | protected: | 1016 | protected: |
1026 | IBootstrapperEngine* m_pEngine; | 1017 | IBootstrapperEngine* m_pEngine; |
1027 | HMODULE m_hModule; | 1018 | HMODULE m_hModule; |
1028 | BA_FUNCTIONS_CREATE_ARGS m_bafCreateArgs; | ||
1029 | BOOTSTRAPPER_CREATE_ARGS m_baCreateArgs; | ||
1030 | BOOTSTRAPPER_COMMAND m_command; | ||
1031 | HWND m_hwndParent; | 1019 | HWND m_hwndParent; |
1032 | }; | 1020 | }; |
diff --git a/src/api/burn/balutil/inc/BalBaseBAFunctionsProc.h b/src/api/burn/balutil/inc/BalBaseBAFunctionsProc.h index 728bd2b5..65eeb0b4 100644 --- a/src/api/burn/balutil/inc/BalBaseBAFunctionsProc.h +++ b/src/api/burn/balutil/inc/BalBaseBAFunctionsProc.h | |||
@@ -1,191 +1,15 @@ | |||
1 | #pragma once | 1 | #pragma once |
2 | // Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. | 2 | // Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. |
3 | 3 | ||
4 | |||
5 | #include "BalBaseBootstrapperApplicationProc.h" | ||
6 | #include "BAFunctions.h" | ||
7 | #include "IBAFunctions.h" | ||
8 | |||
9 | static HRESULT BalBaseBAFunctionsProcOnThemeLoaded( | ||
10 | __in IBAFunctions* pBAFunctions, | ||
11 | __in BA_FUNCTIONS_ONTHEMELOADED_ARGS* pArgs, | ||
12 | __inout BA_FUNCTIONS_ONTHEMELOADED_RESULTS* /*pResults*/ | ||
13 | ) | ||
14 | { | ||
15 | return pBAFunctions->OnThemeLoaded(pArgs->hWnd); | ||
16 | } | ||
17 | |||
18 | static HRESULT BalBaseBAFunctionsProcWndProc( | ||
19 | __in IBAFunctions* pBAFunctions, | ||
20 | __in BA_FUNCTIONS_WNDPROC_ARGS* pArgs, | ||
21 | __inout BA_FUNCTIONS_WNDPROC_RESULTS* pResults | ||
22 | ) | ||
23 | { | ||
24 | return pBAFunctions->WndProc(pArgs->hWnd, pArgs->uMsg, pArgs->wParam, pArgs->lParam, &pResults->fProcessed, &pResults->lResult); | ||
25 | } | ||
26 | |||
27 | static HRESULT BalBaseBAFunctionsProcOnThemeControlLoading( | ||
28 | __in IBAFunctions* pBAFunctions, | ||
29 | __in BA_FUNCTIONS_ONTHEMECONTROLLOADING_ARGS* pArgs, | ||
30 | __inout BA_FUNCTIONS_ONTHEMECONTROLLOADING_RESULTS* pResults | ||
31 | ) | ||
32 | { | ||
33 | return pBAFunctions->OnThemeControlLoading(pArgs->wzName, &pResults->fProcessed, &pResults->wId, &pResults->dwAutomaticBehaviorType); | ||
34 | } | ||
35 | |||
36 | static HRESULT BalBaseBAFunctionsProcOnThemeControlWmCommand( | ||
37 | __in IBAFunctions* pBAFunctions, | ||
38 | __in BA_FUNCTIONS_ONTHEMECONTROLWMCOMMAND_ARGS* pArgs, | ||
39 | __inout BA_FUNCTIONS_ONTHEMECONTROLWMCOMMAND_RESULTS* pResults | ||
40 | ) | ||
41 | { | ||
42 | return pBAFunctions->OnThemeControlWmCommand(pArgs->wParam, pArgs->wzName, pArgs->wId, pArgs->hWnd, &pResults->fProcessed, &pResults->lResult); | ||
43 | } | ||
44 | |||
45 | static HRESULT BalBaseBAFunctionsProcOnThemeControlWmNotify( | ||
46 | __in IBAFunctions* pBAFunctions, | ||
47 | __in BA_FUNCTIONS_ONTHEMECONTROLWMNOTIFY_ARGS* pArgs, | ||
48 | __inout BA_FUNCTIONS_ONTHEMECONTROLWMNOTIFY_RESULTS* pResults | ||
49 | ) | ||
50 | { | ||
51 | return pBAFunctions->OnThemeControlWmNotify(pArgs->lParam, pArgs->wzName, pArgs->wId, pArgs->hWnd, &pResults->fProcessed, &pResults->lResult); | ||
52 | } | ||
53 | |||
54 | static HRESULT BalBaseBAFunctionsProcOnThemeControlLoaded( | ||
55 | __in IBAFunctions* pBAFunctions, | ||
56 | __in BA_FUNCTIONS_ONTHEMECONTROLLOADED_ARGS* pArgs, | ||
57 | __inout BA_FUNCTIONS_ONTHEMECONTROLLOADED_RESULTS* pResults | ||
58 | ) | ||
59 | { | ||
60 | return pBAFunctions->OnThemeControlLoaded(pArgs->wzName, pArgs->wId, pArgs->hWnd, &pResults->fProcessed); | ||
61 | } | ||
62 | |||
63 | /******************************************************************* | 4 | /******************************************************************* |
64 | BalBaseBAFunctionsProc - requires pvContext to be of type IBAFunctions. | 5 | BalBaseBAFunctionsProc - requires pvContext to be of type IBAFunctions. |
65 | Provides a default mapping between the message based BAFunctions interface and | 6 | Provides a default mapping between the message based BAFunctions interface and |
66 | the COM-based BAFunctions interface. | 7 | the COM-based BAFunctions interface. |
67 | 8 | ||
68 | *******************************************************************/ | 9 | *******************************************************************/ |
69 | static HRESULT WINAPI BalBaseBAFunctionsProc( | 10 | HRESULT WINAPI BalBaseBAFunctionsProc( |
70 | __in BA_FUNCTIONS_MESSAGE message, | 11 | __in BA_FUNCTIONS_MESSAGE message, |
71 | __in const LPVOID pvArgs, | 12 | __in const LPVOID pvArgs, |
72 | __inout LPVOID pvResults, | 13 | __inout LPVOID pvResults, |
73 | __in_opt LPVOID pvContext | 14 | __in_opt LPVOID pvContext |
74 | ) | 15 | ); |
75 | { | ||
76 | IBAFunctions* pBAFunctions = reinterpret_cast<IBAFunctions*>(pvContext); | ||
77 | HRESULT hr = pBAFunctions->BAFunctionsProc(message, pvArgs, pvResults, pvContext); | ||
78 | |||
79 | if (E_NOTIMPL == hr) | ||
80 | { | ||
81 | switch (message) | ||
82 | { | ||
83 | case BA_FUNCTIONS_MESSAGE_ONDETECTBEGIN: | ||
84 | case BA_FUNCTIONS_MESSAGE_ONDETECTCOMPLETE: | ||
85 | case BA_FUNCTIONS_MESSAGE_ONPLANBEGIN: | ||
86 | case BA_FUNCTIONS_MESSAGE_ONPLANCOMPLETE: | ||
87 | case BA_FUNCTIONS_MESSAGE_ONSTARTUP: | ||
88 | case BA_FUNCTIONS_MESSAGE_ONSHUTDOWN: | ||
89 | case BA_FUNCTIONS_MESSAGE_ONDETECTFORWARDCOMPATIBLEBUNDLE: | ||
90 | case BA_FUNCTIONS_MESSAGE_ONDETECTUPDATEBEGIN: | ||
91 | case BA_FUNCTIONS_MESSAGE_ONDETECTUPDATE: | ||
92 | case BA_FUNCTIONS_MESSAGE_ONDETECTUPDATECOMPLETE: | ||
93 | case BA_FUNCTIONS_MESSAGE_ONDETECTRELATEDBUNDLE: | ||
94 | case BA_FUNCTIONS_MESSAGE_ONDETECTPACKAGEBEGIN: | ||
95 | case BA_FUNCTIONS_MESSAGE_ONDETECTRELATEDMSIPACKAGE: | ||
96 | case BA_FUNCTIONS_MESSAGE_ONDETECTPATCHTARGET: | ||
97 | case BA_FUNCTIONS_MESSAGE_ONDETECTMSIFEATURE: | ||
98 | case BA_FUNCTIONS_MESSAGE_ONDETECTPACKAGECOMPLETE: | ||
99 | case BA_FUNCTIONS_MESSAGE_ONPLANRELATEDBUNDLE: | ||
100 | case BA_FUNCTIONS_MESSAGE_ONPLANPACKAGEBEGIN: | ||
101 | case BA_FUNCTIONS_MESSAGE_ONPLANPATCHTARGET: | ||
102 | case BA_FUNCTIONS_MESSAGE_ONPLANMSIFEATURE: | ||
103 | case BA_FUNCTIONS_MESSAGE_ONPLANPACKAGECOMPLETE: | ||
104 | case BA_FUNCTIONS_MESSAGE_ONAPPLYBEGIN: | ||
105 | case BA_FUNCTIONS_MESSAGE_ONELEVATEBEGIN: | ||
106 | case BA_FUNCTIONS_MESSAGE_ONELEVATECOMPLETE: | ||
107 | case BA_FUNCTIONS_MESSAGE_ONPROGRESS: | ||
108 | case BA_FUNCTIONS_MESSAGE_ONERROR: | ||
109 | case BA_FUNCTIONS_MESSAGE_ONREGISTERBEGIN: | ||
110 | case BA_FUNCTIONS_MESSAGE_ONREGISTERCOMPLETE: | ||
111 | case BA_FUNCTIONS_MESSAGE_ONCACHEBEGIN: | ||
112 | case BA_FUNCTIONS_MESSAGE_ONCACHEPACKAGEBEGIN: | ||
113 | case BA_FUNCTIONS_MESSAGE_ONCACHEACQUIREBEGIN: | ||
114 | case BA_FUNCTIONS_MESSAGE_ONCACHEACQUIREPROGRESS: | ||
115 | case BA_FUNCTIONS_MESSAGE_ONCACHEACQUIRERESOLVING: | ||
116 | case BA_FUNCTIONS_MESSAGE_ONCACHEACQUIRECOMPLETE: | ||
117 | case BA_FUNCTIONS_MESSAGE_ONCACHEVERIFYBEGIN: | ||
118 | case BA_FUNCTIONS_MESSAGE_ONCACHEVERIFYCOMPLETE: | ||
119 | case BA_FUNCTIONS_MESSAGE_ONCACHEPACKAGECOMPLETE: | ||
120 | case BA_FUNCTIONS_MESSAGE_ONCACHECOMPLETE: | ||
121 | case BA_FUNCTIONS_MESSAGE_ONEXECUTEBEGIN: | ||
122 | case BA_FUNCTIONS_MESSAGE_ONEXECUTEPACKAGEBEGIN: | ||
123 | case BA_FUNCTIONS_MESSAGE_ONEXECUTEPATCHTARGET: | ||
124 | case BA_FUNCTIONS_MESSAGE_ONEXECUTEPROGRESS: | ||
125 | case BA_FUNCTIONS_MESSAGE_ONEXECUTEMSIMESSAGE: | ||
126 | case BA_FUNCTIONS_MESSAGE_ONEXECUTEFILESINUSE: | ||
127 | case BA_FUNCTIONS_MESSAGE_ONEXECUTEPACKAGECOMPLETE: | ||
128 | case BA_FUNCTIONS_MESSAGE_ONEXECUTECOMPLETE: | ||
129 | case BA_FUNCTIONS_MESSAGE_ONUNREGISTERBEGIN: | ||
130 | case BA_FUNCTIONS_MESSAGE_ONUNREGISTERCOMPLETE: | ||
131 | case BA_FUNCTIONS_MESSAGE_ONAPPLYCOMPLETE: | ||
132 | case BA_FUNCTIONS_MESSAGE_ONLAUNCHAPPROVEDEXEBEGIN: | ||
133 | case BA_FUNCTIONS_MESSAGE_ONLAUNCHAPPROVEDEXECOMPLETE: | ||
134 | case BA_FUNCTIONS_MESSAGE_ONPLANMSIPACKAGE: | ||
135 | case BA_FUNCTIONS_MESSAGE_ONBEGINMSITRANSACTIONBEGIN: | ||
136 | case BA_FUNCTIONS_MESSAGE_ONBEGINMSITRANSACTIONCOMPLETE: | ||
137 | case BA_FUNCTIONS_MESSAGE_ONCOMMITMSITRANSACTIONBEGIN: | ||
138 | case BA_FUNCTIONS_MESSAGE_ONCOMMITMSITRANSACTIONCOMPLETE: | ||
139 | case BA_FUNCTIONS_MESSAGE_ONROLLBACKMSITRANSACTIONBEGIN: | ||
140 | case BA_FUNCTIONS_MESSAGE_ONROLLBACKMSITRANSACTIONCOMPLETE: | ||
141 | case BA_FUNCTIONS_MESSAGE_ONPAUSEAUTOMATICUPDATESBEGIN: | ||
142 | case BA_FUNCTIONS_MESSAGE_ONPAUSEAUTOMATICUPDATESCOMPLETE: | ||
143 | case BA_FUNCTIONS_MESSAGE_ONSYSTEMRESTOREPOINTBEGIN: | ||
144 | case BA_FUNCTIONS_MESSAGE_ONSYSTEMRESTOREPOINTCOMPLETE: | ||
145 | case BA_FUNCTIONS_MESSAGE_ONPLANNEDPACKAGE: | ||
146 | case BA_FUNCTIONS_MESSAGE_ONPLANFORWARDCOMPATIBLEBUNDLE: | ||
147 | case BA_FUNCTIONS_MESSAGE_ONCACHEVERIFYPROGRESS: | ||
148 | case BA_FUNCTIONS_MESSAGE_ONCACHECONTAINERORPAYLOADVERIFYBEGIN: | ||
149 | case BA_FUNCTIONS_MESSAGE_ONCACHECONTAINERORPAYLOADVERIFYCOMPLETE: | ||
150 | case BA_FUNCTIONS_MESSAGE_ONCACHECONTAINERORPAYLOADVERIFYPROGRESS: | ||
151 | case BA_FUNCTIONS_MESSAGE_ONCACHEPAYLOADEXTRACTBEGIN: | ||
152 | case BA_FUNCTIONS_MESSAGE_ONCACHEPAYLOADEXTRACTCOMPLETE: | ||
153 | case BA_FUNCTIONS_MESSAGE_ONCACHEPAYLOADEXTRACTPROGRESS: | ||
154 | case BA_FUNCTIONS_MESSAGE_ONPLANROLLBACKBOUNDARY: | ||
155 | case BA_FUNCTIONS_MESSAGE_ONSETUPDATEBEGIN: | ||
156 | case BA_FUNCTIONS_MESSAGE_ONSETUPDATECOMPLETE: | ||
157 | case BA_FUNCTIONS_MESSAGE_ONDETECTCOMPATIBLEMSIPACKAGE: | ||
158 | case BA_FUNCTIONS_MESSAGE_ONPLANCOMPATIBLEMSIPACKAGEBEGIN: | ||
159 | case BA_FUNCTIONS_MESSAGE_ONPLANCOMPATIBLEMSIPACKAGECOMPLETE: | ||
160 | case BA_FUNCTIONS_MESSAGE_ONPLANNEDCOMPATIBLEPACKAGE: | ||
161 | case BA_FUNCTIONS_MESSAGE_ONPLANRESTORERELATEDBUNDLE: | ||
162 | case BA_FUNCTIONS_MESSAGE_ONPLANRELATEDBUNDLETYPE: | ||
163 | case BA_FUNCTIONS_MESSAGE_ONAPPLYDOWNGRADE: | ||
164 | case BA_FUNCTIONS_MESSAGE_ONEXECUTEPROCESSCANCEL: | ||
165 | case BA_FUNCTIONS_MESSAGE_ONDETECTRELATEDBUNDLEPACKAGE: | ||
166 | case BA_FUNCTIONS_MESSAGE_ONCACHEPACKAGENONVITALVALIDATIONFAILURE: | ||
167 | hr = BalBaseBootstrapperApplicationProc((BOOTSTRAPPER_APPLICATION_MESSAGE)message, pvArgs, pvResults, pvContext); | ||
168 | break; | ||
169 | case BA_FUNCTIONS_MESSAGE_ONTHEMELOADED: | ||
170 | hr = BalBaseBAFunctionsProcOnThemeLoaded(pBAFunctions, reinterpret_cast<BA_FUNCTIONS_ONTHEMELOADED_ARGS*>(pvArgs), reinterpret_cast<BA_FUNCTIONS_ONTHEMELOADED_RESULTS*>(pvResults)); | ||
171 | break; | ||
172 | case BA_FUNCTIONS_MESSAGE_WNDPROC: | ||
173 | hr = BalBaseBAFunctionsProcWndProc(pBAFunctions, reinterpret_cast<BA_FUNCTIONS_WNDPROC_ARGS*>(pvArgs), reinterpret_cast<BA_FUNCTIONS_WNDPROC_RESULTS*>(pvResults)); | ||
174 | break; | ||
175 | case BA_FUNCTIONS_MESSAGE_ONTHEMECONTROLLOADING: | ||
176 | hr = BalBaseBAFunctionsProcOnThemeControlLoading(pBAFunctions, reinterpret_cast<BA_FUNCTIONS_ONTHEMECONTROLLOADING_ARGS*>(pvArgs), reinterpret_cast<BA_FUNCTIONS_ONTHEMECONTROLLOADING_RESULTS*>(pvResults)); | ||
177 | break; | ||
178 | case BA_FUNCTIONS_MESSAGE_ONTHEMECONTROLWMCOMMAND: | ||
179 | hr = BalBaseBAFunctionsProcOnThemeControlWmCommand(pBAFunctions, reinterpret_cast<BA_FUNCTIONS_ONTHEMECONTROLWMCOMMAND_ARGS*>(pvArgs), reinterpret_cast<BA_FUNCTIONS_ONTHEMECONTROLWMCOMMAND_RESULTS*>(pvResults)); | ||
180 | break; | ||
181 | case BA_FUNCTIONS_MESSAGE_ONTHEMECONTROLWMNOTIFY: | ||
182 | hr = BalBaseBAFunctionsProcOnThemeControlWmNotify(pBAFunctions, reinterpret_cast<BA_FUNCTIONS_ONTHEMECONTROLWMNOTIFY_ARGS*>(pvArgs), reinterpret_cast<BA_FUNCTIONS_ONTHEMECONTROLWMNOTIFY_RESULTS*>(pvResults)); | ||
183 | break; | ||
184 | case BA_FUNCTIONS_MESSAGE_ONTHEMECONTROLLOADED: | ||
185 | hr = BalBaseBAFunctionsProcOnThemeControlLoaded(pBAFunctions, reinterpret_cast<BA_FUNCTIONS_ONTHEMECONTROLLOADED_ARGS*>(pvArgs), reinterpret_cast<BA_FUNCTIONS_ONTHEMECONTROLLOADED_RESULTS*>(pvResults)); | ||
186 | break; | ||
187 | } | ||
188 | } | ||
189 | |||
190 | return hr; | ||
191 | } | ||
diff --git a/src/api/burn/balutil/inc/BalBaseBootstrapperApplication.h b/src/api/burn/balutil/inc/BalBaseBootstrapperApplication.h index ae7b2a93..30c75fb6 100644 --- a/src/api/burn/balutil/inc/BalBaseBootstrapperApplication.h +++ b/src/api/burn/balutil/inc/BalBaseBootstrapperApplication.h | |||
@@ -3,8 +3,6 @@ | |||
3 | #include <windows.h> | 3 | #include <windows.h> |
4 | #include <msiquery.h> | 4 | #include <msiquery.h> |
5 | 5 | ||
6 | #include "BootstrapperEngine.h" | ||
7 | #include "BootstrapperApplication.h" | ||
8 | #include "IBootstrapperEngine.h" | 6 | #include "IBootstrapperEngine.h" |
9 | #include "IBootstrapperApplication.h" | 7 | #include "IBootstrapperApplication.h" |
10 | 8 | ||
@@ -12,7 +10,9 @@ | |||
12 | #include "balinfo.h" | 10 | #include "balinfo.h" |
13 | #include "balretry.h" | 11 | #include "balretry.h" |
14 | 12 | ||
15 | class CBalBaseBootstrapperApplication : public IBootstrapperApplication | 13 | #define CBalBaseBootstrapperApplication CBootstrapperApplication |
14 | |||
15 | class CBootstrapperApplication : public IBootstrapperApplication | ||
16 | { | 16 | { |
17 | public: // IUnknown | 17 | public: // IUnknown |
18 | virtual STDMETHODIMP QueryInterface( | 18 | virtual STDMETHODIMP QueryInterface( |
@@ -65,8 +65,7 @@ public: // IBootstrapperApplication | |||
65 | virtual STDMETHODIMP_(HRESULT) BAProc( | 65 | virtual STDMETHODIMP_(HRESULT) BAProc( |
66 | __in BOOTSTRAPPER_APPLICATION_MESSAGE /*message*/, | 66 | __in BOOTSTRAPPER_APPLICATION_MESSAGE /*message*/, |
67 | __in const LPVOID /*pvArgs*/, | 67 | __in const LPVOID /*pvArgs*/, |
68 | __inout LPVOID /*pvResults*/, | 68 | __inout LPVOID /*pvResults*/ |
69 | __in_opt LPVOID /*pvContext*/ | ||
70 | ) | 69 | ) |
71 | { | 70 | { |
72 | return E_NOTIMPL; | 71 | return E_NOTIMPL; |
@@ -76,10 +75,35 @@ public: // IBootstrapperApplication | |||
76 | __in BOOTSTRAPPER_APPLICATION_MESSAGE /*message*/, | 75 | __in BOOTSTRAPPER_APPLICATION_MESSAGE /*message*/, |
77 | __in const LPVOID /*pvArgs*/, | 76 | __in const LPVOID /*pvArgs*/, |
78 | __inout LPVOID /*pvResults*/, | 77 | __inout LPVOID /*pvResults*/, |
79 | __inout HRESULT* /*phr*/, | 78 | __inout HRESULT* /*phr*/ |
80 | __in_opt LPVOID /*pvContext*/ | 79 | ) |
80 | { | ||
81 | } | ||
82 | |||
83 | virtual STDMETHODIMP OnCreate( | ||
84 | __in IBootstrapperEngine* pEngine, | ||
85 | __in BOOTSTRAPPER_COMMAND* pCommand | ||
86 | ) | ||
87 | { | ||
88 | HRESULT hr = S_OK; | ||
89 | |||
90 | m_commandDisplay = pCommand->display; | ||
91 | |||
92 | hr = BalInfoParseCommandLine(&m_BalInfoCommand, pCommand); | ||
93 | BalExitOnFailure(hr, "Failed to parse command line with balutil."); | ||
94 | |||
95 | pEngine->AddRef(); | ||
96 | m_pEngine = pEngine; | ||
97 | |||
98 | LExit: | ||
99 | return hr; | ||
100 | } | ||
101 | |||
102 | virtual STDMETHODIMP OnDestroy( | ||
103 | __in BOOL /*fReload*/ | ||
81 | ) | 104 | ) |
82 | { | 105 | { |
106 | return S_OK; | ||
83 | } | 107 | } |
84 | 108 | ||
85 | virtual STDMETHODIMP OnStartup() | 109 | virtual STDMETHODIMP OnStartup() |
@@ -429,7 +453,7 @@ public: // IBootstrapperApplication | |||
429 | m_dwProgressPercentage = dwProgressPercentage; | 453 | m_dwProgressPercentage = dwProgressPercentage; |
430 | m_dwOverallProgressPercentage = dwOverallProgressPercentage; | 454 | m_dwOverallProgressPercentage = dwOverallProgressPercentage; |
431 | 455 | ||
432 | if (BOOTSTRAPPER_DISPLAY_EMBEDDED == m_display) | 456 | if (BOOTSTRAPPER_DISPLAY_EMBEDDED == m_commandDisplay) |
433 | { | 457 | { |
434 | hr = m_pEngine->SendEmbeddedProgress(m_dwProgressPercentage, m_dwOverallProgressPercentage, &nResult); | 458 | hr = m_pEngine->SendEmbeddedProgress(m_dwProgressPercentage, m_dwOverallProgressPercentage, &nResult); |
435 | BalExitOnFailure(hr, "Failed to send embedded overall progress."); | 459 | BalExitOnFailure(hr, "Failed to send embedded overall progress."); |
@@ -463,7 +487,7 @@ public: // IBootstrapperApplication | |||
463 | { | 487 | { |
464 | BalRetryErrorOccurred(wzPackageId, dwCode); | 488 | BalRetryErrorOccurred(wzPackageId, dwCode); |
465 | 489 | ||
466 | if (BOOTSTRAPPER_DISPLAY_EMBEDDED == m_display) | 490 | if (BOOTSTRAPPER_DISPLAY_EMBEDDED == m_commandDisplay) |
467 | { | 491 | { |
468 | HRESULT hr = m_pEngine->SendEmbeddedError(dwCode, wzError, dwUIHint, pResult); | 492 | HRESULT hr = m_pEngine->SendEmbeddedError(dwCode, wzError, dwUIHint, pResult); |
469 | if (FAILED(hr)) | 493 | if (FAILED(hr)) |
@@ -475,7 +499,7 @@ public: // IBootstrapperApplication | |||
475 | { | 499 | { |
476 | *pResult = IDCANCEL; | 500 | *pResult = IDCANCEL; |
477 | } | 501 | } |
478 | else if (BOOTSTRAPPER_DISPLAY_FULL == m_display) | 502 | else if (BOOTSTRAPPER_DISPLAY_FULL == m_commandDisplay) |
479 | { | 503 | { |
480 | if (BOOTSTRAPPER_ERROR_TYPE_HTTP_AUTH_SERVER == errorType || BOOTSTRAPPER_ERROR_TYPE_HTTP_AUTH_PROXY == errorType) | 504 | if (BOOTSTRAPPER_ERROR_TYPE_HTTP_AUTH_SERVER == errorType || BOOTSTRAPPER_ERROR_TYPE_HTTP_AUTH_PROXY == errorType) |
481 | { | 505 | { |
@@ -553,7 +577,7 @@ public: // IBootstrapperApplication | |||
553 | 577 | ||
554 | // Send progress even though we don't update the numbers to at least give the caller an opportunity | 578 | // Send progress even though we don't update the numbers to at least give the caller an opportunity |
555 | // to cancel. | 579 | // to cancel. |
556 | if (BOOTSTRAPPER_DISPLAY_EMBEDDED == m_display) | 580 | if (BOOTSTRAPPER_DISPLAY_EMBEDDED == m_commandDisplay) |
557 | { | 581 | { |
558 | hr = m_pEngine->SendEmbeddedProgress(m_dwProgressPercentage, m_dwOverallProgressPercentage, &nResult); | 582 | hr = m_pEngine->SendEmbeddedProgress(m_dwProgressPercentage, m_dwOverallProgressPercentage, &nResult); |
559 | BalExitOnFailure(hr, "Failed to send embedded cache progress."); | 583 | BalExitOnFailure(hr, "Failed to send embedded cache progress."); |
@@ -733,7 +757,7 @@ public: // IBootstrapperApplication | |||
733 | 757 | ||
734 | // Send progress even though we don't update the numbers to at least give the caller an opportunity | 758 | // Send progress even though we don't update the numbers to at least give the caller an opportunity |
735 | // to cancel. | 759 | // to cancel. |
736 | if (BOOTSTRAPPER_DISPLAY_EMBEDDED == m_display) | 760 | if (BOOTSTRAPPER_DISPLAY_EMBEDDED == m_commandDisplay) |
737 | { | 761 | { |
738 | hr = m_pEngine->SendEmbeddedProgress(m_dwProgressPercentage, m_dwOverallProgressPercentage, &nResult); | 762 | hr = m_pEngine->SendEmbeddedProgress(m_dwProgressPercentage, m_dwOverallProgressPercentage, &nResult); |
739 | BalExitOnFailure(hr, "Failed to send embedded execute progress."); | 763 | BalExitOnFailure(hr, "Failed to send embedded execute progress."); |
@@ -848,7 +872,7 @@ public: // IBootstrapperApplication | |||
848 | { | 872 | { |
849 | HRESULT hr = S_OK; | 873 | HRESULT hr = S_OK; |
850 | BOOL fRestartRequired = BOOTSTRAPPER_APPLY_RESTART_REQUIRED == restart; | 874 | BOOL fRestartRequired = BOOTSTRAPPER_APPLY_RESTART_REQUIRED == restart; |
851 | BOOL fShouldBlockRestart = BOOTSTRAPPER_DISPLAY_FULL <= m_display && BAL_INFO_RESTART_PROMPT >= m_BalInfoCommand.restart; | 875 | BOOL fShouldBlockRestart = BOOTSTRAPPER_DISPLAY_FULL <= m_commandDisplay && BAL_INFO_RESTART_PROMPT >= m_BalInfoCommand.restart; |
852 | 876 | ||
853 | if (fRestartRequired && !fShouldBlockRestart) | 877 | if (fRestartRequired && !fShouldBlockRestart) |
854 | { | 878 | { |
@@ -1050,20 +1074,6 @@ public: // IBootstrapperApplication | |||
1050 | return S_OK; | 1074 | return S_OK; |
1051 | } | 1075 | } |
1052 | 1076 | ||
1053 | virtual STDMETHODIMP OnSetUpdateBegin() | ||
1054 | { | ||
1055 | return S_OK; | ||
1056 | } | ||
1057 | |||
1058 | virtual STDMETHODIMP OnSetUpdateComplete( | ||
1059 | __in HRESULT /*hrStatus*/, | ||
1060 | __in_z_opt LPCWSTR /*wzPreviousPackageId*/, | ||
1061 | __in_z_opt LPCWSTR /*wzNewPackageId*/ | ||
1062 | ) | ||
1063 | { | ||
1064 | return S_OK; | ||
1065 | } | ||
1066 | |||
1067 | virtual STDMETHODIMP OnPlanRestoreRelatedBundle( | 1077 | virtual STDMETHODIMP OnPlanRestoreRelatedBundle( |
1068 | __in_z LPCWSTR /*wzBundleId*/, | 1078 | __in_z LPCWSTR /*wzBundleId*/, |
1069 | __in BOOTSTRAPPER_REQUEST_STATE /*recommendedState*/, | 1079 | __in BOOTSTRAPPER_REQUEST_STATE /*recommendedState*/, |
@@ -1127,22 +1137,6 @@ public: // IBootstrapperApplication | |||
1127 | return S_OK; | 1137 | return S_OK; |
1128 | } | 1138 | } |
1129 | 1139 | ||
1130 | public: //CBalBaseBootstrapperApplication | ||
1131 | virtual STDMETHODIMP Initialize( | ||
1132 | __in const BOOTSTRAPPER_CREATE_ARGS* pCreateArgs | ||
1133 | ) | ||
1134 | { | ||
1135 | HRESULT hr = S_OK; | ||
1136 | |||
1137 | m_display = pCreateArgs->pCommand->display; | ||
1138 | |||
1139 | hr = BalInfoParseCommandLine(&m_BalInfoCommand, pCreateArgs->pCommand); | ||
1140 | BalExitOnFailure(hr, "Failed to parse command line with balutil."); | ||
1141 | |||
1142 | LExit: | ||
1143 | return hr; | ||
1144 | } | ||
1145 | |||
1146 | protected: | 1140 | protected: |
1147 | // | 1141 | // |
1148 | // PromptCancel - prompts the user to close (if not forced). | 1142 | // PromptCancel - prompts the user to close (if not forced). |
@@ -1195,16 +1189,14 @@ protected: | |||
1195 | } | 1189 | } |
1196 | 1190 | ||
1197 | CBalBaseBootstrapperApplication( | 1191 | CBalBaseBootstrapperApplication( |
1198 | __in IBootstrapperEngine* pEngine, | ||
1199 | __in DWORD dwRetryCount = 0, | 1192 | __in DWORD dwRetryCount = 0, |
1200 | __in DWORD dwRetryTimeout = 1000 | 1193 | __in DWORD dwRetryTimeout = 1000 |
1201 | ) | 1194 | ) |
1202 | { | 1195 | { |
1203 | m_cReferences = 1; | 1196 | m_cReferences = 1; |
1204 | m_display = BOOTSTRAPPER_DISPLAY_UNKNOWN; | 1197 | m_commandDisplay = BOOTSTRAPPER_DISPLAY_UNKNOWN; |
1205 | 1198 | ||
1206 | pEngine->AddRef(); | 1199 | m_pEngine = NULL; |
1207 | m_pEngine = pEngine; | ||
1208 | 1200 | ||
1209 | ::InitializeCriticalSection(&m_csCanceled); | 1201 | ::InitializeCriticalSection(&m_csCanceled); |
1210 | m_fCanceled = FALSE; | 1202 | m_fCanceled = FALSE; |
@@ -1230,12 +1222,12 @@ protected: | |||
1230 | CRITICAL_SECTION m_csCanceled; | 1222 | CRITICAL_SECTION m_csCanceled; |
1231 | BOOL m_fCanceled; | 1223 | BOOL m_fCanceled; |
1232 | 1224 | ||
1225 | IBootstrapperEngine* m_pEngine; | ||
1233 | BAL_INFO_COMMAND m_BalInfoCommand; | 1226 | BAL_INFO_COMMAND m_BalInfoCommand; |
1234 | 1227 | ||
1235 | private: | 1228 | private: |
1236 | long m_cReferences; | 1229 | long m_cReferences; |
1237 | BOOTSTRAPPER_DISPLAY m_display; | 1230 | BOOTSTRAPPER_DISPLAY m_commandDisplay; |
1238 | IBootstrapperEngine* m_pEngine; | ||
1239 | 1231 | ||
1240 | BOOL m_fRollingBack; | 1232 | BOOL m_fRollingBack; |
1241 | 1233 | ||
diff --git a/src/api/burn/balutil/inc/BalBaseBootstrapperApplicationProc.h b/src/api/burn/balutil/inc/BalBaseBootstrapperApplicationProc.h deleted file mode 100644 index 34739ba3..00000000 --- a/src/api/burn/balutil/inc/BalBaseBootstrapperApplicationProc.h +++ /dev/null | |||
@@ -1,1045 +0,0 @@ | |||
1 | #pragma once | ||
2 | // Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. | ||
3 | |||
4 | |||
5 | #include <windows.h> | ||
6 | |||
7 | #include "BootstrapperEngine.h" | ||
8 | #include "BootstrapperApplication.h" | ||
9 | #include "IBootstrapperEngine.h" | ||
10 | #include "IBootstrapperApplication.h" | ||
11 | |||
12 | static HRESULT BalBaseBAProcOnDetectBegin( | ||
13 | __in IBootstrapperApplication* pBA, | ||
14 | __in BA_ONDETECTBEGIN_ARGS* pArgs, | ||
15 | __inout BA_ONDETECTBEGIN_RESULTS* pResults | ||
16 | ) | ||
17 | { | ||
18 | return pBA->OnDetectBegin(pArgs->fCached, pArgs->registrationType, pArgs->cPackages, &pResults->fCancel); | ||
19 | } | ||
20 | |||
21 | static HRESULT BalBaseBAProcOnDetectComplete( | ||
22 | __in IBootstrapperApplication* pBA, | ||
23 | __in BA_ONDETECTCOMPLETE_ARGS* pArgs, | ||
24 | __inout BA_ONDETECTCOMPLETE_RESULTS* /*pResults*/ | ||
25 | ) | ||
26 | { | ||
27 | return pBA->OnDetectComplete(pArgs->hrStatus, pArgs->fEligibleForCleanup); | ||
28 | } | ||
29 | |||
30 | static HRESULT BalBaseBAProcOnPlanBegin( | ||
31 | __in IBootstrapperApplication* pBA, | ||
32 | __in BA_ONPLANBEGIN_ARGS* pArgs, | ||
33 | __inout BA_ONPLANBEGIN_RESULTS* pResults | ||
34 | ) | ||
35 | { | ||
36 | return pBA->OnPlanBegin(pArgs->cPackages, &pResults->fCancel); | ||
37 | } | ||
38 | |||
39 | static HRESULT BalBaseBAProcOnPlanComplete( | ||
40 | __in IBootstrapperApplication* pBA, | ||
41 | __in BA_ONPLANCOMPLETE_ARGS* pArgs, | ||
42 | __inout BA_ONPLANCOMPLETE_RESULTS* /*pResults*/ | ||
43 | ) | ||
44 | { | ||
45 | return pBA->OnPlanComplete(pArgs->hrStatus); | ||
46 | } | ||
47 | |||
48 | static HRESULT BalBaseBAProcOnStartup( | ||
49 | __in IBootstrapperApplication* pBA, | ||
50 | __in BA_ONSTARTUP_ARGS* /*pArgs*/, | ||
51 | __inout BA_ONSTARTUP_RESULTS* /*pResults*/ | ||
52 | ) | ||
53 | { | ||
54 | return pBA->OnStartup(); | ||
55 | } | ||
56 | |||
57 | static HRESULT BalBaseBAProcOnShutdown( | ||
58 | __in IBootstrapperApplication* pBA, | ||
59 | __in BA_ONSHUTDOWN_ARGS* /*pArgs*/, | ||
60 | __inout BA_ONSHUTDOWN_RESULTS* pResults | ||
61 | ) | ||
62 | { | ||
63 | return pBA->OnShutdown(&pResults->action); | ||
64 | } | ||
65 | |||
66 | static HRESULT BalBaseBAProcOnDetectForwardCompatibleBundle( | ||
67 | __in IBootstrapperApplication* pBA, | ||
68 | __in BA_ONDETECTFORWARDCOMPATIBLEBUNDLE_ARGS* pArgs, | ||
69 | __inout BA_ONDETECTFORWARDCOMPATIBLEBUNDLE_RESULTS* pResults | ||
70 | ) | ||
71 | { | ||
72 | return pBA->OnDetectForwardCompatibleBundle(pArgs->wzBundleId, pArgs->relationType, pArgs->wzBundleTag, pArgs->fPerMachine, pArgs->wzVersion, pArgs->fMissingFromCache, &pResults->fCancel); | ||
73 | } | ||
74 | |||
75 | static HRESULT BalBaseBAProcOnDetectUpdateBegin( | ||
76 | __in IBootstrapperApplication* pBA, | ||
77 | __in BA_ONDETECTUPDATEBEGIN_ARGS* pArgs, | ||
78 | __inout BA_ONDETECTUPDATEBEGIN_RESULTS* pResults | ||
79 | ) | ||
80 | { | ||
81 | return pBA->OnDetectUpdateBegin(pArgs->wzUpdateLocation, &pResults->fCancel, &pResults->fSkip); | ||
82 | } | ||
83 | |||
84 | static HRESULT BalBaseBAProcOnDetectUpdate( | ||
85 | __in IBootstrapperApplication* pBA, | ||
86 | __in BA_ONDETECTUPDATE_ARGS* pArgs, | ||
87 | __inout BA_ONDETECTUPDATE_RESULTS* pResults | ||
88 | ) | ||
89 | { | ||
90 | return pBA->OnDetectUpdate(pArgs->wzUpdateLocation, pArgs->dw64Size, pArgs->wzHash, pArgs->hashAlgorithm, pArgs->wzVersion, pArgs->wzTitle, pArgs->wzSummary, pArgs->wzContentType, pArgs->wzContent, &pResults->fCancel, &pResults->fStopProcessingUpdates); | ||
91 | } | ||
92 | |||
93 | static HRESULT BalBaseBAProcOnDetectUpdateComplete( | ||
94 | __in IBootstrapperApplication* pBA, | ||
95 | __in BA_ONDETECTUPDATECOMPLETE_ARGS* pArgs, | ||
96 | __inout BA_ONDETECTUPDATECOMPLETE_RESULTS* pResults | ||
97 | ) | ||
98 | { | ||
99 | return pBA->OnDetectUpdateComplete(pArgs->hrStatus, &pResults->fIgnoreError); | ||
100 | } | ||
101 | |||
102 | static HRESULT BalBaseBAProcOnDetectRelatedBundle( | ||
103 | __in IBootstrapperApplication* pBA, | ||
104 | __in BA_ONDETECTRELATEDBUNDLE_ARGS* pArgs, | ||
105 | __inout BA_ONDETECTRELATEDBUNDLE_RESULTS* pResults | ||
106 | ) | ||
107 | { | ||
108 | return pBA->OnDetectRelatedBundle(pArgs->wzBundleId, pArgs->relationType, pArgs->wzBundleTag, pArgs->fPerMachine, pArgs->wzVersion, pArgs->fMissingFromCache, &pResults->fCancel); | ||
109 | } | ||
110 | |||
111 | static HRESULT BalBaseBAProcOnDetectPackageBegin( | ||
112 | __in IBootstrapperApplication* pBA, | ||
113 | __in BA_ONDETECTPACKAGEBEGIN_ARGS* pArgs, | ||
114 | __inout BA_ONDETECTPACKAGEBEGIN_RESULTS* pResults | ||
115 | ) | ||
116 | { | ||
117 | return pBA->OnDetectPackageBegin(pArgs->wzPackageId, &pResults->fCancel); | ||
118 | } | ||
119 | |||
120 | static HRESULT BalBaseBAProcOnDetectCompatiblePackage( | ||
121 | __in IBootstrapperApplication* pBA, | ||
122 | __in BA_ONDETECTCOMPATIBLEMSIPACKAGE_ARGS* pArgs, | ||
123 | __inout BA_ONDETECTCOMPATIBLEMSIPACKAGE_RESULTS* pResults | ||
124 | ) | ||
125 | { | ||
126 | return pBA->OnDetectCompatibleMsiPackage(pArgs->wzPackageId, pArgs->wzCompatiblePackageId, pArgs->wzCompatiblePackageVersion, &pResults->fCancel); | ||
127 | } | ||
128 | |||
129 | static HRESULT BalBaseBAProcOnDetectRelatedMsiPackage( | ||
130 | __in IBootstrapperApplication* pBA, | ||
131 | __in BA_ONDETECTRELATEDMSIPACKAGE_ARGS* pArgs, | ||
132 | __inout BA_ONDETECTRELATEDMSIPACKAGE_RESULTS* pResults | ||
133 | ) | ||
134 | { | ||
135 | return pBA->OnDetectRelatedMsiPackage(pArgs->wzPackageId, pArgs->wzUpgradeCode, pArgs->wzProductCode, pArgs->fPerMachine, pArgs->wzVersion, pArgs->operation, &pResults->fCancel); | ||
136 | } | ||
137 | |||
138 | static HRESULT BalBaseBAProcOnDetectPatchTarget( | ||
139 | __in IBootstrapperApplication* pBA, | ||
140 | __in BA_ONDETECTPATCHTARGET_ARGS* pArgs, | ||
141 | __inout BA_ONDETECTPATCHTARGET_RESULTS* pResults | ||
142 | ) | ||
143 | { | ||
144 | return pBA->OnDetectPatchTarget(pArgs->wzPackageId, pArgs->wzProductCode, pArgs->patchState, &pResults->fCancel); | ||
145 | } | ||
146 | |||
147 | static HRESULT BalBaseBAProcOnDetectMsiFeature( | ||
148 | __in IBootstrapperApplication* pBA, | ||
149 | __in BA_ONDETECTMSIFEATURE_ARGS* pArgs, | ||
150 | __inout BA_ONDETECTMSIFEATURE_RESULTS* pResults | ||
151 | ) | ||
152 | { | ||
153 | return pBA->OnDetectMsiFeature(pArgs->wzPackageId, pArgs->wzFeatureId, pArgs->state, &pResults->fCancel); | ||
154 | } | ||
155 | |||
156 | static HRESULT BalBaseBAProcOnDetectPackageComplete( | ||
157 | __in IBootstrapperApplication* pBA, | ||
158 | __in BA_ONDETECTPACKAGECOMPLETE_ARGS* pArgs, | ||
159 | __inout BA_ONDETECTPACKAGECOMPLETE_RESULTS* /*pResults*/ | ||
160 | ) | ||
161 | { | ||
162 | return pBA->OnDetectPackageComplete(pArgs->wzPackageId, pArgs->hrStatus, pArgs->state, pArgs->fCached); | ||
163 | } | ||
164 | |||
165 | static HRESULT BalBaseBAProcOnPlanRelatedBundle( | ||
166 | __in IBootstrapperApplication* pBA, | ||
167 | __in BA_ONPLANRELATEDBUNDLE_ARGS* pArgs, | ||
168 | __inout BA_ONPLANRELATEDBUNDLE_RESULTS* pResults | ||
169 | ) | ||
170 | { | ||
171 | return pBA->OnPlanRelatedBundle(pArgs->wzBundleId, pArgs->recommendedState, &pResults->requestedState, &pResults->fCancel); | ||
172 | } | ||
173 | |||
174 | static HRESULT BalBaseBAProcOnPlanRollbackBoundary( | ||
175 | __in IBootstrapperApplication* pBA, | ||
176 | __in BA_ONPLANROLLBACKBOUNDARY_ARGS* pArgs, | ||
177 | __inout BA_ONPLANROLLBACKBOUNDARY_RESULTS* pResults | ||
178 | ) | ||
179 | { | ||
180 | return pBA->OnPlanRollbackBoundary(pArgs->wzRollbackBoundaryId, pArgs->fRecommendedTransaction, &pResults->fTransaction, &pResults->fCancel); | ||
181 | } | ||
182 | |||
183 | static HRESULT BalBaseBAProcOnPlanPackageBegin( | ||
184 | __in IBootstrapperApplication* pBA, | ||
185 | __in BA_ONPLANPACKAGEBEGIN_ARGS* pArgs, | ||
186 | __inout BA_ONPLANPACKAGEBEGIN_RESULTS* pResults | ||
187 | ) | ||
188 | { | ||
189 | return pBA->OnPlanPackageBegin(pArgs->wzPackageId, pArgs->state, pArgs->fCached, pArgs->installCondition, pArgs->repairCondition, pArgs->recommendedState, pArgs->recommendedCacheType, &pResults->requestedState, &pResults->requestedCacheType, &pResults->fCancel); | ||
190 | } | ||
191 | |||
192 | static HRESULT BalBaseBAProcOnPlanCompatibleMsiPackageBegin( | ||
193 | __in IBootstrapperApplication* pBA, | ||
194 | __in BA_ONPLANCOMPATIBLEMSIPACKAGEBEGIN_ARGS* pArgs, | ||
195 | __inout BA_ONPLANCOMPATIBLEMSIPACKAGEBEGIN_RESULTS* pResults | ||
196 | ) | ||
197 | { | ||
198 | return pBA->OnPlanCompatibleMsiPackageBegin(pArgs->wzPackageId, pArgs->wzCompatiblePackageId, pArgs->wzCompatiblePackageVersion, pArgs->fRecommendedRemove, &pResults->fRequestRemove, &pResults->fCancel); | ||
199 | } | ||
200 | |||
201 | static HRESULT BalBaseBAProcOnPlanCompatibleMsiPackageComplete( | ||
202 | __in IBootstrapperApplication* pBA, | ||
203 | __in BA_ONPLANCOMPATIBLEMSIPACKAGECOMPLETE_ARGS* pArgs, | ||
204 | __inout BA_ONPLANCOMPATIBLEMSIPACKAGECOMPLETE_RESULTS* /*pResults*/ | ||
205 | ) | ||
206 | { | ||
207 | return pBA->OnPlanCompatibleMsiPackageComplete(pArgs->wzPackageId, pArgs->wzCompatiblePackageId, pArgs->hrStatus, pArgs->fRequestedRemove); | ||
208 | } | ||
209 | |||
210 | static HRESULT BalBaseBAProcOnPlanPatchTarget( | ||
211 | __in IBootstrapperApplication* pBA, | ||
212 | __in BA_ONPLANPATCHTARGET_ARGS* pArgs, | ||
213 | __inout BA_ONPLANPATCHTARGET_RESULTS* pResults | ||
214 | ) | ||
215 | { | ||
216 | return pBA->OnPlanPatchTarget(pArgs->wzPackageId, pArgs->wzProductCode, pArgs->recommendedState, &pResults->requestedState, &pResults->fCancel); | ||
217 | } | ||
218 | |||
219 | static HRESULT BalBaseBAProcOnPlanMsiFeature( | ||
220 | __in IBootstrapperApplication* pBA, | ||
221 | __in BA_ONPLANMSIFEATURE_ARGS* pArgs, | ||
222 | __inout BA_ONPLANMSIFEATURE_RESULTS* pResults | ||
223 | ) | ||
224 | { | ||
225 | return pBA->OnPlanMsiFeature(pArgs->wzPackageId, pArgs->wzFeatureId, pArgs->recommendedState, &pResults->requestedState, &pResults->fCancel); | ||
226 | } | ||
227 | |||
228 | static HRESULT BalBaseBAProcOnPlanPackageComplete( | ||
229 | __in IBootstrapperApplication* pBA, | ||
230 | __in BA_ONPLANPACKAGECOMPLETE_ARGS* pArgs, | ||
231 | __inout BA_ONPLANPACKAGECOMPLETE_RESULTS* /*pResults*/ | ||
232 | ) | ||
233 | { | ||
234 | return pBA->OnPlanPackageComplete(pArgs->wzPackageId, pArgs->hrStatus, pArgs->requested); | ||
235 | } | ||
236 | |||
237 | static HRESULT BalBaseBAProcOnPlannedCompatiblePackage( | ||
238 | __in IBootstrapperApplication* pBA, | ||
239 | __in BA_ONPLANNEDCOMPATIBLEPACKAGE_ARGS* pArgs, | ||
240 | __inout BA_ONPLANNEDCOMPATIBLEPACKAGE_RESULTS* /*pResults*/ | ||
241 | ) | ||
242 | { | ||
243 | return pBA->OnPlannedCompatiblePackage(pArgs->wzPackageId, pArgs->wzCompatiblePackageId, pArgs->fRemove); | ||
244 | } | ||
245 | |||
246 | static HRESULT BalBaseBAProcOnPlannedPackage( | ||
247 | __in IBootstrapperApplication* pBA, | ||
248 | __in BA_ONPLANNEDPACKAGE_ARGS* pArgs, | ||
249 | __inout BA_ONPLANNEDPACKAGE_RESULTS* /*pResults*/ | ||
250 | ) | ||
251 | { | ||
252 | return pBA->OnPlannedPackage(pArgs->wzPackageId, pArgs->execute, pArgs->rollback, pArgs->fPlannedCache, pArgs->fPlannedUncache); | ||
253 | } | ||
254 | |||
255 | static HRESULT BalBaseBAProcOnApplyBegin( | ||
256 | __in IBootstrapperApplication* pBA, | ||
257 | __in BA_ONAPPLYBEGIN_ARGS* pArgs, | ||
258 | __inout BA_ONAPPLYBEGIN_RESULTS* pResults | ||
259 | ) | ||
260 | { | ||
261 | return pBA->OnApplyBegin(pArgs->dwPhaseCount, &pResults->fCancel); | ||
262 | } | ||
263 | |||
264 | static HRESULT BalBaseBAProcOnElevateBegin( | ||
265 | __in IBootstrapperApplication* pBA, | ||
266 | __in BA_ONELEVATEBEGIN_ARGS* /*pArgs*/, | ||
267 | __inout BA_ONELEVATEBEGIN_RESULTS* pResults | ||
268 | ) | ||
269 | { | ||
270 | return pBA->OnElevateBegin(&pResults->fCancel); | ||
271 | } | ||
272 | |||
273 | static HRESULT BalBaseBAProcOnElevateComplete( | ||
274 | __in IBootstrapperApplication* pBA, | ||
275 | __in BA_ONELEVATECOMPLETE_ARGS* pArgs, | ||
276 | __inout BA_ONELEVATECOMPLETE_RESULTS* /*pResults*/ | ||
277 | ) | ||
278 | { | ||
279 | return pBA->OnElevateComplete(pArgs->hrStatus); | ||
280 | } | ||
281 | |||
282 | static HRESULT BalBaseBAProcOnProgress( | ||
283 | __in IBootstrapperApplication* pBA, | ||
284 | __in BA_ONPROGRESS_ARGS* pArgs, | ||
285 | __inout BA_ONPROGRESS_RESULTS* pResults | ||
286 | ) | ||
287 | { | ||
288 | return pBA->OnProgress(pArgs->dwProgressPercentage, pArgs->dwOverallPercentage, &pResults->fCancel); | ||
289 | } | ||
290 | |||
291 | static HRESULT BalBaseBAProcOnError( | ||
292 | __in IBootstrapperApplication* pBA, | ||
293 | __in BA_ONERROR_ARGS* pArgs, | ||
294 | __inout BA_ONERROR_RESULTS* pResults | ||
295 | ) | ||
296 | { | ||
297 | return pBA->OnError(pArgs->errorType, pArgs->wzPackageId, pArgs->dwCode, pArgs->wzError, pArgs->dwUIHint, pArgs->cData, pArgs->rgwzData, pArgs->nRecommendation, &pResults->nResult); | ||
298 | } | ||
299 | |||
300 | static HRESULT BalBaseBAProcOnRegisterBegin( | ||
301 | __in IBootstrapperApplication* pBA, | ||
302 | __in BA_ONREGISTERBEGIN_ARGS* pArgs, | ||
303 | __inout BA_ONREGISTERBEGIN_RESULTS* pResults | ||
304 | ) | ||
305 | { | ||
306 | return pBA->OnRegisterBegin(pArgs->recommendedRegistrationType, &pResults->fCancel, &pResults->registrationType); | ||
307 | } | ||
308 | |||
309 | static HRESULT BalBaseBAProcOnRegisterComplete( | ||
310 | __in IBootstrapperApplication* pBA, | ||
311 | __in BA_ONREGISTERCOMPLETE_ARGS* pArgs, | ||
312 | __inout BA_ONREGISTERCOMPLETE_RESULTS* /*pResults*/ | ||
313 | ) | ||
314 | { | ||
315 | return pBA->OnRegisterComplete(pArgs->hrStatus); | ||
316 | } | ||
317 | |||
318 | static HRESULT BalBaseBAProcOnCacheBegin( | ||
319 | __in IBootstrapperApplication* pBA, | ||
320 | __in BA_ONCACHEBEGIN_ARGS* /*pArgs*/, | ||
321 | __inout BA_ONCACHEBEGIN_RESULTS* pResults | ||
322 | ) | ||
323 | { | ||
324 | return pBA->OnCacheBegin(&pResults->fCancel); | ||
325 | } | ||
326 | |||
327 | static HRESULT BalBaseBAProcOnCachePackageBegin( | ||
328 | __in IBootstrapperApplication* pBA, | ||
329 | __in BA_ONCACHEPACKAGEBEGIN_ARGS* pArgs, | ||
330 | __inout BA_ONCACHEPACKAGEBEGIN_RESULTS* pResults | ||
331 | ) | ||
332 | { | ||
333 | return pBA->OnCachePackageBegin(pArgs->wzPackageId, pArgs->cCachePayloads, pArgs->dw64PackageCacheSize, pArgs->fVital, &pResults->fCancel); | ||
334 | } | ||
335 | |||
336 | static HRESULT BalBaseBAProcOnCacheAcquireBegin( | ||
337 | __in IBootstrapperApplication* pBA, | ||
338 | __in BA_ONCACHEACQUIREBEGIN_ARGS* pArgs, | ||
339 | __inout BA_ONCACHEACQUIREBEGIN_RESULTS* pResults | ||
340 | ) | ||
341 | { | ||
342 | return pBA->OnCacheAcquireBegin(pArgs->wzPackageOrContainerId, pArgs->wzPayloadId, pArgs->wzSource, pArgs->wzDownloadUrl, pArgs->wzPayloadContainerId, pArgs->recommendation, &pResults->action, &pResults->fCancel); | ||
343 | } | ||
344 | |||
345 | static HRESULT BalBaseBAProcOnCacheAcquireProgress( | ||
346 | __in IBootstrapperApplication* pBA, | ||
347 | __in BA_ONCACHEACQUIREPROGRESS_ARGS* pArgs, | ||
348 | __inout BA_ONCACHEACQUIREPROGRESS_RESULTS* pResults | ||
349 | ) | ||
350 | { | ||
351 | return pBA->OnCacheAcquireProgress(pArgs->wzPackageOrContainerId, pArgs->wzPayloadId, pArgs->dw64Progress, pArgs->dw64Total, pArgs->dwOverallPercentage, &pResults->fCancel); | ||
352 | } | ||
353 | |||
354 | static HRESULT BalBaseBAProcOnCacheAcquireResolving( | ||
355 | __in IBootstrapperApplication* pBA, | ||
356 | __in BA_ONCACHEACQUIRERESOLVING_ARGS* pArgs, | ||
357 | __inout BA_ONCACHEACQUIRERESOLVING_RESULTS* pResults | ||
358 | ) | ||
359 | { | ||
360 | return pBA->OnCacheAcquireResolving(pArgs->wzPackageOrContainerId, pArgs->wzPayloadId, pArgs->rgSearchPaths, pArgs->cSearchPaths, pArgs->fFoundLocal, pArgs->dwRecommendedSearchPath, pArgs->wzDownloadUrl, pArgs->wzPayloadContainerId, pArgs->recommendation, &pResults->dwChosenSearchPath, &pResults->action, &pResults->fCancel); | ||
361 | } | ||
362 | |||
363 | static HRESULT BalBaseBAProcOnCacheAcquireComplete( | ||
364 | __in IBootstrapperApplication* pBA, | ||
365 | __in BA_ONCACHEACQUIRECOMPLETE_ARGS* pArgs, | ||
366 | __inout BA_ONCACHEACQUIRECOMPLETE_RESULTS* pResults | ||
367 | ) | ||
368 | { | ||
369 | return pBA->OnCacheAcquireComplete(pArgs->wzPackageOrContainerId, pArgs->wzPayloadId, pArgs->hrStatus, pArgs->recommendation, &pResults->action); | ||
370 | } | ||
371 | |||
372 | static HRESULT BalBaseBAProcOnCacheVerifyBegin( | ||
373 | __in IBootstrapperApplication* pBA, | ||
374 | __in BA_ONCACHEVERIFYBEGIN_ARGS* pArgs, | ||
375 | __inout BA_ONCACHEVERIFYBEGIN_RESULTS* pResults | ||
376 | ) | ||
377 | { | ||
378 | return pBA->OnCacheVerifyBegin(pArgs->wzPackageOrContainerId, pArgs->wzPayloadId, &pResults->fCancel); | ||
379 | } | ||
380 | |||
381 | static HRESULT BalBaseBAProcOnCacheVerifyProgress( | ||
382 | __in IBootstrapperApplication* pBA, | ||
383 | __in BA_ONCACHEVERIFYPROGRESS_ARGS* pArgs, | ||
384 | __inout BA_ONCACHEVERIFYPROGRESS_RESULTS* pResults | ||
385 | ) | ||
386 | { | ||
387 | return pBA->OnCacheVerifyProgress(pArgs->wzPackageOrContainerId, pArgs->wzPayloadId, pArgs->dw64Progress, pArgs->dw64Total, pArgs->dwOverallPercentage, pArgs->verifyStep, &pResults->fCancel); | ||
388 | } | ||
389 | |||
390 | static HRESULT BalBaseBAProcOnCacheVerifyComplete( | ||
391 | __in IBootstrapperApplication* pBA, | ||
392 | __in BA_ONCACHEVERIFYCOMPLETE_ARGS* pArgs, | ||
393 | __inout BA_ONCACHEVERIFYCOMPLETE_RESULTS* pResults | ||
394 | ) | ||
395 | { | ||
396 | return pBA->OnCacheVerifyComplete(pArgs->wzPackageOrContainerId, pArgs->wzPayloadId, pArgs->hrStatus, pArgs->recommendation, &pResults->action); | ||
397 | } | ||
398 | |||
399 | static HRESULT BalBaseBAProcOnCachePackageComplete( | ||
400 | __in IBootstrapperApplication* pBA, | ||
401 | __in BA_ONCACHEPACKAGECOMPLETE_ARGS* pArgs, | ||
402 | __inout BA_ONCACHEPACKAGECOMPLETE_RESULTS* pResults | ||
403 | ) | ||
404 | { | ||
405 | return pBA->OnCachePackageComplete(pArgs->wzPackageId, pArgs->hrStatus, pArgs->recommendation, &pResults->action); | ||
406 | } | ||
407 | |||
408 | static HRESULT BalBaseBAProcOnCacheComplete( | ||
409 | __in IBootstrapperApplication* pBA, | ||
410 | __in BA_ONCACHECOMPLETE_ARGS* pArgs, | ||
411 | __inout BA_ONCACHECOMPLETE_RESULTS* /*pResults*/ | ||
412 | ) | ||
413 | { | ||
414 | return pBA->OnCacheComplete(pArgs->hrStatus); | ||
415 | } | ||
416 | |||
417 | static HRESULT BalBaseBAProcOnExecuteBegin( | ||
418 | __in IBootstrapperApplication* pBA, | ||
419 | __in BA_ONEXECUTEBEGIN_ARGS* pArgs, | ||
420 | __inout BA_ONEXECUTEBEGIN_RESULTS* pResults | ||
421 | ) | ||
422 | { | ||
423 | return pBA->OnExecuteBegin(pArgs->cExecutingPackages, &pResults->fCancel); | ||
424 | } | ||
425 | |||
426 | static HRESULT BalBaseBAProcOnExecutePackageBegin( | ||
427 | __in IBootstrapperApplication* pBA, | ||
428 | __in BA_ONEXECUTEPACKAGEBEGIN_ARGS* pArgs, | ||
429 | __inout BA_ONEXECUTEPACKAGEBEGIN_RESULTS* pResults | ||
430 | ) | ||
431 | { | ||
432 | return pBA->OnExecutePackageBegin(pArgs->wzPackageId, pArgs->fExecute, pArgs->action, pArgs->uiLevel, pArgs->fDisableExternalUiHandler, &pResults->fCancel); | ||
433 | } | ||
434 | |||
435 | static HRESULT BalBaseBAProcOnExecutePatchTarget( | ||
436 | __in IBootstrapperApplication* pBA, | ||
437 | __in BA_ONEXECUTEPATCHTARGET_ARGS* pArgs, | ||
438 | __inout BA_ONEXECUTEPATCHTARGET_RESULTS* pResults | ||
439 | ) | ||
440 | { | ||
441 | return pBA->OnExecutePatchTarget(pArgs->wzPackageId, pArgs->wzTargetProductCode, &pResults->fCancel); | ||
442 | } | ||
443 | |||
444 | static HRESULT BalBaseBAProcOnExecuteProgress( | ||
445 | __in IBootstrapperApplication* pBA, | ||
446 | __in BA_ONEXECUTEPROGRESS_ARGS* pArgs, | ||
447 | __inout BA_ONEXECUTEPROGRESS_RESULTS* pResults | ||
448 | ) | ||
449 | { | ||
450 | return pBA->OnExecuteProgress(pArgs->wzPackageId, pArgs->dwProgressPercentage, pArgs->dwOverallPercentage, &pResults->fCancel); | ||
451 | } | ||
452 | |||
453 | static HRESULT BalBaseBAProcOnExecuteMsiMessage( | ||
454 | __in IBootstrapperApplication* pBA, | ||
455 | __in BA_ONEXECUTEMSIMESSAGE_ARGS* pArgs, | ||
456 | __inout BA_ONEXECUTEMSIMESSAGE_RESULTS* pResults | ||
457 | ) | ||
458 | { | ||
459 | return pBA->OnExecuteMsiMessage(pArgs->wzPackageId, pArgs->messageType, pArgs->dwUIHint, pArgs->wzMessage, pArgs->cData, pArgs->rgwzData, pArgs->nRecommendation, &pResults->nResult); | ||
460 | } | ||
461 | |||
462 | static HRESULT BalBaseBAProcOnExecuteFilesInUse( | ||
463 | __in IBootstrapperApplication* pBA, | ||
464 | __in BA_ONEXECUTEFILESINUSE_ARGS* pArgs, | ||
465 | __inout BA_ONEXECUTEFILESINUSE_RESULTS* pResults | ||
466 | ) | ||
467 | { | ||
468 | return pBA->OnExecuteFilesInUse(pArgs->wzPackageId, pArgs->cFiles, pArgs->rgwzFiles, pArgs->nRecommendation, pArgs->source, &pResults->nResult); | ||
469 | } | ||
470 | |||
471 | static HRESULT BalBaseBAProcOnExecutePackageComplete( | ||
472 | __in IBootstrapperApplication* pBA, | ||
473 | __in BA_ONEXECUTEPACKAGECOMPLETE_ARGS* pArgs, | ||
474 | __inout BA_ONEXECUTEPACKAGECOMPLETE_RESULTS* pResults | ||
475 | ) | ||
476 | { | ||
477 | return pBA->OnExecutePackageComplete(pArgs->wzPackageId, pArgs->hrStatus, pArgs->restart, pArgs->recommendation, &pResults->action); | ||
478 | } | ||
479 | |||
480 | static HRESULT BalBaseBAProcOnExecuteProcessCancel( | ||
481 | __in IBootstrapperApplication* pBA, | ||
482 | __in BA_ONEXECUTEPROCESSCANCEL_ARGS* pArgs, | ||
483 | __inout BA_ONEXECUTEPROCESSCANCEL_RESULTS* pResults | ||
484 | ) | ||
485 | { | ||
486 | return pBA->OnExecuteProcessCancel(pArgs->wzPackageId, pArgs->dwProcessId, pArgs->recommendation, &pResults->action); | ||
487 | } | ||
488 | |||
489 | static HRESULT BalBaseBAProcOnExecuteComplete( | ||
490 | __in IBootstrapperApplication* pBA, | ||
491 | __in BA_ONEXECUTECOMPLETE_ARGS* pArgs, | ||
492 | __inout BA_ONEXECUTECOMPLETE_RESULTS* /*pResults*/ | ||
493 | ) | ||
494 | { | ||
495 | return pBA->OnExecuteComplete(pArgs->hrStatus); | ||
496 | } | ||
497 | |||
498 | static HRESULT BalBaseBAProcOnUnregisterBegin( | ||
499 | __in IBootstrapperApplication* pBA, | ||
500 | __in BA_ONUNREGISTERBEGIN_ARGS* pArgs, | ||
501 | __inout BA_ONUNREGISTERBEGIN_RESULTS* pResults | ||
502 | ) | ||
503 | { | ||
504 | return pBA->OnUnregisterBegin(pArgs->recommendedRegistrationType, &pResults->registrationType); | ||
505 | } | ||
506 | |||
507 | static HRESULT BalBaseBAProcOnUnregisterComplete( | ||
508 | __in IBootstrapperApplication* pBA, | ||
509 | __in BA_ONUNREGISTERCOMPLETE_ARGS* pArgs, | ||
510 | __inout BA_ONUNREGISTERCOMPLETE_RESULTS* /*pResults*/ | ||
511 | ) | ||
512 | { | ||
513 | return pBA->OnUnregisterComplete(pArgs->hrStatus); | ||
514 | } | ||
515 | |||
516 | static HRESULT BalBaseBAProcOnApplyComplete( | ||
517 | __in IBootstrapperApplication* pBA, | ||
518 | __in BA_ONAPPLYCOMPLETE_ARGS* pArgs, | ||
519 | __inout BA_ONAPPLYCOMPLETE_RESULTS* pResults | ||
520 | ) | ||
521 | { | ||
522 | return pBA->OnApplyComplete(pArgs->hrStatus, pArgs->restart, pArgs->recommendation, &pResults->action); | ||
523 | } | ||
524 | |||
525 | static HRESULT BalBaseBAProcOnLaunchApprovedExeBegin( | ||
526 | __in IBootstrapperApplication* pBA, | ||
527 | __in BA_ONLAUNCHAPPROVEDEXEBEGIN_ARGS* /*pArgs*/, | ||
528 | __inout BA_ONLAUNCHAPPROVEDEXEBEGIN_RESULTS* pResults | ||
529 | ) | ||
530 | { | ||
531 | return pBA->OnLaunchApprovedExeBegin(&pResults->fCancel); | ||
532 | } | ||
533 | |||
534 | static HRESULT BalBaseBAProcOnLaunchApprovedExeComplete( | ||
535 | __in IBootstrapperApplication* pBA, | ||
536 | __in BA_ONLAUNCHAPPROVEDEXECOMPLETE_ARGS* pArgs, | ||
537 | __inout BA_ONLAUNCHAPPROVEDEXECOMPLETE_RESULTS* /*pResults*/ | ||
538 | ) | ||
539 | { | ||
540 | return pBA->OnLaunchApprovedExeComplete(pArgs->hrStatus, pArgs->dwProcessId); | ||
541 | } | ||
542 | |||
543 | static HRESULT BalBaseBAProcOnPlanMsiPackage( | ||
544 | __in IBootstrapperApplication* pBA, | ||
545 | __in BA_ONPLANMSIPACKAGE_ARGS* pArgs, | ||
546 | __inout BA_ONPLANMSIPACKAGE_RESULTS* pResults | ||
547 | ) | ||
548 | { | ||
549 | return pBA->OnPlanMsiPackage(pArgs->wzPackageId, pArgs->fExecute, pArgs->action, pArgs->recommendedFileVersioning, &pResults->fCancel, &pResults->actionMsiProperty, &pResults->uiLevel, &pResults->fDisableExternalUiHandler, &pResults->fileVersioning); | ||
550 | } | ||
551 | |||
552 | static HRESULT BalBaseBAProcOnBeginMsiTransactionBegin( | ||
553 | __in IBootstrapperApplication* pBA, | ||
554 | __in BA_ONBEGINMSITRANSACTIONBEGIN_ARGS* pArgs, | ||
555 | __inout BA_ONBEGINMSITRANSACTIONBEGIN_RESULTS* pResults | ||
556 | ) | ||
557 | { | ||
558 | return pBA->OnBeginMsiTransactionBegin(pArgs->wzTransactionId, &pResults->fCancel); | ||
559 | } | ||
560 | |||
561 | static HRESULT BalBaseBAProcOnBeginMsiTransactionComplete( | ||
562 | __in IBootstrapperApplication* pBA, | ||
563 | __in BA_ONBEGINMSITRANSACTIONCOMPLETE_ARGS* pArgs, | ||
564 | __inout BA_ONBEGINMSITRANSACTIONCOMPLETE_RESULTS* /*pResults*/ | ||
565 | ) | ||
566 | { | ||
567 | return pBA->OnBeginMsiTransactionComplete(pArgs->wzTransactionId, pArgs->hrStatus); | ||
568 | } | ||
569 | |||
570 | static HRESULT BalBaseBAProcOnCommitMsiTransactionBegin( | ||
571 | __in IBootstrapperApplication* pBA, | ||
572 | __in BA_ONCOMMITMSITRANSACTIONBEGIN_ARGS* pArgs, | ||
573 | __inout BA_ONCOMMITMSITRANSACTIONBEGIN_RESULTS* pResults | ||
574 | ) | ||
575 | { | ||
576 | return pBA->OnCommitMsiTransactionBegin(pArgs->wzTransactionId, &pResults->fCancel); | ||
577 | } | ||
578 | |||
579 | static HRESULT BalBaseBAProcOnCommitMsiTransactionComplete( | ||
580 | __in IBootstrapperApplication* pBA, | ||
581 | __in BA_ONCOMMITMSITRANSACTIONCOMPLETE_ARGS* pArgs, | ||
582 | __inout BA_ONCOMMITMSITRANSACTIONCOMPLETE_RESULTS* pResults | ||
583 | ) | ||
584 | { | ||
585 | return pBA->OnCommitMsiTransactionComplete(pArgs->wzTransactionId, pArgs->hrStatus, pArgs->restart, pArgs->recommendation, &pResults->action); | ||
586 | } | ||
587 | |||
588 | static HRESULT BalBaseBAProcOnRollbackMsiTransactionBegin( | ||
589 | __in IBootstrapperApplication* pBA, | ||
590 | __in BA_ONROLLBACKMSITRANSACTIONBEGIN_ARGS* pArgs, | ||
591 | __inout BA_ONROLLBACKMSITRANSACTIONBEGIN_RESULTS* /*pResults*/ | ||
592 | ) | ||
593 | { | ||
594 | return pBA->OnRollbackMsiTransactionBegin(pArgs->wzTransactionId); | ||
595 | } | ||
596 | |||
597 | static HRESULT BalBaseBAProcOnRollbackMsiTransactionComplete( | ||
598 | __in IBootstrapperApplication* pBA, | ||
599 | __in BA_ONROLLBACKMSITRANSACTIONCOMPLETE_ARGS* pArgs, | ||
600 | __inout BA_ONROLLBACKMSITRANSACTIONCOMPLETE_RESULTS* pResults | ||
601 | ) | ||
602 | { | ||
603 | return pBA->OnRollbackMsiTransactionComplete(pArgs->wzTransactionId, pArgs->hrStatus, pArgs->restart, pArgs->recommendation, &pResults->action); | ||
604 | } | ||
605 | |||
606 | static HRESULT BalBaseBAProcOnPauseAutomaticUpdatesBegin( | ||
607 | __in IBootstrapperApplication* pBA, | ||
608 | __in BA_ONPAUSEAUTOMATICUPDATESBEGIN_ARGS* /*pArgs*/, | ||
609 | __inout BA_ONPAUSEAUTOMATICUPDATESBEGIN_RESULTS* /*pResults*/ | ||
610 | ) | ||
611 | { | ||
612 | return pBA->OnPauseAutomaticUpdatesBegin(); | ||
613 | } | ||
614 | |||
615 | static HRESULT BalBaseBAProcOnPauseAutomaticUpdatesComplete( | ||
616 | __in IBootstrapperApplication* pBA, | ||
617 | __in BA_ONPAUSEAUTOMATICUPDATESCOMPLETE_ARGS* pArgs, | ||
618 | __inout BA_ONPAUSEAUTOMATICUPDATESCOMPLETE_RESULTS* /*pResults*/ | ||
619 | ) | ||
620 | { | ||
621 | return pBA->OnPauseAutomaticUpdatesComplete(pArgs->hrStatus); | ||
622 | } | ||
623 | |||
624 | static HRESULT BalBaseBAProcOnSystemRestorePointBegin( | ||
625 | __in IBootstrapperApplication* pBA, | ||
626 | __in BA_ONSYSTEMRESTOREPOINTBEGIN_ARGS* /*pArgs*/, | ||
627 | __inout BA_ONSYSTEMRESTOREPOINTBEGIN_RESULTS* /*pResults*/ | ||
628 | ) | ||
629 | { | ||
630 | return pBA->OnSystemRestorePointBegin(); | ||
631 | } | ||
632 | |||
633 | static HRESULT BalBaseBAProcOnSystemRestorePointComplete( | ||
634 | __in IBootstrapperApplication* pBA, | ||
635 | __in BA_ONSYSTEMRESTOREPOINTCOMPLETE_ARGS* pArgs, | ||
636 | __inout BA_ONSYSTEMRESTOREPOINTCOMPLETE_RESULTS* /*pResults*/ | ||
637 | ) | ||
638 | { | ||
639 | return pBA->OnSystemRestorePointComplete(pArgs->hrStatus); | ||
640 | } | ||
641 | |||
642 | static HRESULT BalBaseBAProcOnPlanForwardCompatibleBundle( | ||
643 | __in IBootstrapperApplication* pBA, | ||
644 | __in BA_ONPLANFORWARDCOMPATIBLEBUNDLE_ARGS* pArgs, | ||
645 | __inout BA_ONPLANFORWARDCOMPATIBLEBUNDLE_RESULTS* pResults | ||
646 | ) | ||
647 | { | ||
648 | return pBA->OnPlanForwardCompatibleBundle(pArgs->wzBundleId, pArgs->relationType, pArgs->wzBundleTag, pArgs->fPerMachine, pArgs->wzVersion, pArgs->fRecommendedIgnoreBundle, &pResults->fCancel, &pResults->fIgnoreBundle); | ||
649 | } | ||
650 | |||
651 | static HRESULT BalBaseBAProcOnCacheContainerOrPayloadVerifyBegin( | ||
652 | __in IBootstrapperApplication* pBA, | ||
653 | __in BA_ONCACHECONTAINERORPAYLOADVERIFYBEGIN_ARGS* pArgs, | ||
654 | __inout BA_ONCACHECONTAINERORPAYLOADVERIFYBEGIN_RESULTS* pResults | ||
655 | ) | ||
656 | { | ||
657 | return pBA->OnCacheContainerOrPayloadVerifyBegin(pArgs->wzPackageOrContainerId, pArgs->wzPayloadId, &pResults->fCancel); | ||
658 | } | ||
659 | |||
660 | static HRESULT BalBaseBAProcOnCacheContainerOrPayloadVerifyProgress( | ||
661 | __in IBootstrapperApplication* pBA, | ||
662 | __in BA_ONCACHECONTAINERORPAYLOADVERIFYPROGRESS_ARGS* pArgs, | ||
663 | __inout BA_ONCACHECONTAINERORPAYLOADVERIFYPROGRESS_RESULTS* pResults | ||
664 | ) | ||
665 | { | ||
666 | return pBA->OnCacheContainerOrPayloadVerifyProgress(pArgs->wzPackageOrContainerId, pArgs->wzPayloadId, pArgs->dw64Progress, pArgs->dw64Total, pArgs->dwOverallPercentage, &pResults->fCancel); | ||
667 | } | ||
668 | |||
669 | static HRESULT BalBaseBAProcOnCacheContainerOrPayloadVerifyComplete( | ||
670 | __in IBootstrapperApplication* pBA, | ||
671 | __in BA_ONCACHECONTAINERORPAYLOADVERIFYCOMPLETE_ARGS* pArgs, | ||
672 | __inout BA_ONCACHECONTAINERORPAYLOADVERIFYCOMPLETE_RESULTS* /*pResults*/ | ||
673 | ) | ||
674 | { | ||
675 | return pBA->OnCacheContainerOrPayloadVerifyComplete(pArgs->wzPackageOrContainerId, pArgs->wzPayloadId, pArgs->hrStatus); | ||
676 | } | ||
677 | |||
678 | static HRESULT BalBaseBAProcOnCachePayloadExtractBegin( | ||
679 | __in IBootstrapperApplication* pBA, | ||
680 | __in BA_ONCACHEPAYLOADEXTRACTBEGIN_ARGS* pArgs, | ||
681 | __inout BA_ONCACHEPAYLOADEXTRACTBEGIN_RESULTS* pResults | ||
682 | ) | ||
683 | { | ||
684 | return pBA->OnCachePayloadExtractBegin(pArgs->wzContainerId, pArgs->wzPayloadId, &pResults->fCancel); | ||
685 | } | ||
686 | |||
687 | static HRESULT BalBaseBAProcOnCachePayloadExtractProgress( | ||
688 | __in IBootstrapperApplication* pBA, | ||
689 | __in BA_ONCACHEPAYLOADEXTRACTPROGRESS_ARGS* pArgs, | ||
690 | __inout BA_ONCACHEPAYLOADEXTRACTPROGRESS_RESULTS* pResults | ||
691 | ) | ||
692 | { | ||
693 | return pBA->OnCachePayloadExtractProgress(pArgs->wzContainerId, pArgs->wzPayloadId, pArgs->dw64Progress, pArgs->dw64Total, pArgs->dwOverallPercentage, &pResults->fCancel); | ||
694 | } | ||
695 | |||
696 | static HRESULT BalBaseBAProcOnCachePayloadExtractComplete( | ||
697 | __in IBootstrapperApplication* pBA, | ||
698 | __in BA_ONCACHEPAYLOADEXTRACTCOMPLETE_ARGS* pArgs, | ||
699 | __inout BA_ONCACHEPAYLOADEXTRACTCOMPLETE_RESULTS* /*pResults*/ | ||
700 | ) | ||
701 | { | ||
702 | return pBA->OnCachePayloadExtractComplete(pArgs->wzContainerId, pArgs->wzPayloadId, pArgs->hrStatus); | ||
703 | } | ||
704 | |||
705 | static HRESULT BalBaseBAProcOnSetUpdateBegin( | ||
706 | __in IBootstrapperApplication* pBA, | ||
707 | __in BA_ONSETUPDATEBEGIN_ARGS* /*pArgs*/, | ||
708 | __inout BA_ONSETUPDATEBEGIN_RESULTS* /*pResults*/ | ||
709 | ) | ||
710 | { | ||
711 | return pBA->OnSetUpdateBegin(); | ||
712 | } | ||
713 | |||
714 | static HRESULT BalBaseBAProcOnSetUpdateComplete( | ||
715 | __in IBootstrapperApplication* pBA, | ||
716 | __in BA_ONSETUPDATECOMPLETE_ARGS* pArgs, | ||
717 | __inout BA_ONSETUPDATECOMPLETE_RESULTS* /*pResults*/ | ||
718 | ) | ||
719 | { | ||
720 | return pBA->OnSetUpdateComplete(pArgs->hrStatus, pArgs->wzPreviousPackageId, pArgs->wzNewPackageId); | ||
721 | } | ||
722 | |||
723 | static HRESULT BalBaseBAProcOnPlanRestoreRelatedBundle( | ||
724 | __in IBootstrapperApplication* pBA, | ||
725 | __in BA_ONPLANRESTORERELATEDBUNDLE_ARGS* pArgs, | ||
726 | __inout BA_ONPLANRESTORERELATEDBUNDLE_RESULTS* pResults | ||
727 | ) | ||
728 | { | ||
729 | return pBA->OnPlanRestoreRelatedBundle(pArgs->wzBundleId, pArgs->recommendedState, &pResults->requestedState, &pResults->fCancel); | ||
730 | } | ||
731 | |||
732 | static HRESULT BalBaseBAProcOnPlanRelatedBundleType( | ||
733 | __in IBootstrapperApplication* pBA, | ||
734 | __in BA_ONPLANRELATEDBUNDLETYPE_ARGS* pArgs, | ||
735 | __inout BA_ONPLANRELATEDBUNDLETYPE_RESULTS* pResults | ||
736 | ) | ||
737 | { | ||
738 | return pBA->OnPlanRelatedBundleType(pArgs->wzBundleId, pArgs->recommendedType, &pResults->requestedType, &pResults->fCancel); | ||
739 | } | ||
740 | |||
741 | static HRESULT BalBaseBAProcOnApplyDowngrade( | ||
742 | __in IBootstrapperApplication* pBA, | ||
743 | __in BA_ONAPPLYDOWNGRADE_ARGS* pArgs, | ||
744 | __inout BA_ONAPPLYDOWNGRADE_RESULTS* pResults | ||
745 | ) | ||
746 | { | ||
747 | return pBA->OnApplyDowngrade(pArgs->hrRecommended, &pResults->hrStatus); | ||
748 | } | ||
749 | |||
750 | static HRESULT BalBaseBAProcOnDetectRelatedBundlePackage( | ||
751 | __in IBootstrapperApplication* pBA, | ||
752 | __in BA_ONDETECTRELATEDBUNDLEPACKAGE_ARGS* pArgs, | ||
753 | __inout BA_ONDETECTRELATEDBUNDLEPACKAGE_RESULTS* pResults | ||
754 | ) | ||
755 | { | ||
756 | return pBA->OnDetectRelatedBundlePackage(pArgs->wzPackageId, pArgs->wzBundleId, pArgs->relationType, pArgs->fPerMachine, pArgs->wzVersion, &pResults->fCancel); | ||
757 | } | ||
758 | |||
759 | static HRESULT BalBaseBAProcOnCachePackageNonVitalValidationFailure( | ||
760 | __in IBootstrapperApplication* pBA, | ||
761 | __in BA_ONCACHEPACKAGENONVITALVALIDATIONFAILURE_ARGS* pArgs, | ||
762 | __inout BA_ONCACHEPACKAGENONVITALVALIDATIONFAILURE_RESULTS* pResults | ||
763 | ) | ||
764 | { | ||
765 | return pBA->OnCachePackageNonVitalValidationFailure(pArgs->wzPackageId, pArgs->hrStatus, pArgs->recommendation, &pResults->action); | ||
766 | } | ||
767 | |||
768 | /******************************************************************* | ||
769 | BalBaseBootstrapperApplicationProc - requires pvContext to be of type IBootstrapperApplication. | ||
770 | Provides a default mapping between the new message based BA interface and | ||
771 | the old COM-based BA interface. | ||
772 | |||
773 | *******************************************************************/ | ||
774 | static HRESULT WINAPI BalBaseBootstrapperApplicationProc( | ||
775 | __in BOOTSTRAPPER_APPLICATION_MESSAGE message, | ||
776 | __in const LPVOID pvArgs, | ||
777 | __inout LPVOID pvResults, | ||
778 | __in_opt LPVOID pvContext | ||
779 | ) | ||
780 | { | ||
781 | IBootstrapperApplication* pBA = reinterpret_cast<IBootstrapperApplication*>(pvContext); | ||
782 | HRESULT hr = pBA->BAProc(message, pvArgs, pvResults, pvContext); | ||
783 | |||
784 | if (E_NOTIMPL == hr) | ||
785 | { | ||
786 | switch (message) | ||
787 | { | ||
788 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONDETECTBEGIN: | ||
789 | hr = BalBaseBAProcOnDetectBegin(pBA, reinterpret_cast<BA_ONDETECTBEGIN_ARGS*>(pvArgs), reinterpret_cast<BA_ONDETECTBEGIN_RESULTS*>(pvResults)); | ||
790 | break; | ||
791 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONDETECTCOMPLETE: | ||
792 | hr = BalBaseBAProcOnDetectComplete(pBA, reinterpret_cast<BA_ONDETECTCOMPLETE_ARGS*>(pvArgs), reinterpret_cast<BA_ONDETECTCOMPLETE_RESULTS*>(pvResults)); | ||
793 | break; | ||
794 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONPLANBEGIN: | ||
795 | hr = BalBaseBAProcOnPlanBegin(pBA, reinterpret_cast<BA_ONPLANBEGIN_ARGS*>(pvArgs), reinterpret_cast<BA_ONPLANBEGIN_RESULTS*>(pvResults)); | ||
796 | break; | ||
797 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONPLANCOMPLETE: | ||
798 | hr = BalBaseBAProcOnPlanComplete(pBA, reinterpret_cast<BA_ONPLANCOMPLETE_ARGS*>(pvArgs), reinterpret_cast<BA_ONPLANCOMPLETE_RESULTS*>(pvResults)); | ||
799 | break; | ||
800 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONSTARTUP: | ||
801 | hr = BalBaseBAProcOnStartup(pBA, reinterpret_cast<BA_ONSTARTUP_ARGS*>(pvArgs), reinterpret_cast<BA_ONSTARTUP_RESULTS*>(pvResults)); | ||
802 | break; | ||
803 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONSHUTDOWN: | ||
804 | hr = BalBaseBAProcOnShutdown(pBA, reinterpret_cast<BA_ONSHUTDOWN_ARGS*>(pvArgs), reinterpret_cast<BA_ONSHUTDOWN_RESULTS*>(pvResults)); | ||
805 | break; | ||
806 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONDETECTFORWARDCOMPATIBLEBUNDLE: | ||
807 | hr = BalBaseBAProcOnDetectForwardCompatibleBundle(pBA, reinterpret_cast<BA_ONDETECTFORWARDCOMPATIBLEBUNDLE_ARGS*>(pvArgs), reinterpret_cast<BA_ONDETECTFORWARDCOMPATIBLEBUNDLE_RESULTS*>(pvResults)); | ||
808 | break; | ||
809 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONDETECTUPDATEBEGIN: | ||
810 | hr = BalBaseBAProcOnDetectUpdateBegin(pBA, reinterpret_cast<BA_ONDETECTUPDATEBEGIN_ARGS*>(pvArgs), reinterpret_cast<BA_ONDETECTUPDATEBEGIN_RESULTS*>(pvResults)); | ||
811 | break; | ||
812 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONDETECTUPDATE: | ||
813 | hr = BalBaseBAProcOnDetectUpdate(pBA, reinterpret_cast<BA_ONDETECTUPDATE_ARGS*>(pvArgs), reinterpret_cast<BA_ONDETECTUPDATE_RESULTS*>(pvResults)); | ||
814 | break; | ||
815 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONDETECTUPDATECOMPLETE: | ||
816 | hr = BalBaseBAProcOnDetectUpdateComplete(pBA, reinterpret_cast<BA_ONDETECTUPDATECOMPLETE_ARGS*>(pvArgs), reinterpret_cast<BA_ONDETECTUPDATECOMPLETE_RESULTS*>(pvResults)); | ||
817 | break; | ||
818 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONDETECTRELATEDBUNDLE: | ||
819 | hr = BalBaseBAProcOnDetectRelatedBundle(pBA, reinterpret_cast<BA_ONDETECTRELATEDBUNDLE_ARGS*>(pvArgs), reinterpret_cast<BA_ONDETECTRELATEDBUNDLE_RESULTS*>(pvResults)); | ||
820 | break; | ||
821 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONDETECTPACKAGEBEGIN: | ||
822 | hr = BalBaseBAProcOnDetectPackageBegin(pBA, reinterpret_cast<BA_ONDETECTPACKAGEBEGIN_ARGS*>(pvArgs), reinterpret_cast<BA_ONDETECTPACKAGEBEGIN_RESULTS*>(pvResults)); | ||
823 | break; | ||
824 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONDETECTRELATEDMSIPACKAGE: | ||
825 | hr = BalBaseBAProcOnDetectRelatedMsiPackage(pBA, reinterpret_cast<BA_ONDETECTRELATEDMSIPACKAGE_ARGS*>(pvArgs), reinterpret_cast<BA_ONDETECTRELATEDMSIPACKAGE_RESULTS*>(pvResults)); | ||
826 | break; | ||
827 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONDETECTPATCHTARGET: | ||
828 | hr = BalBaseBAProcOnDetectPatchTarget(pBA, reinterpret_cast<BA_ONDETECTPATCHTARGET_ARGS*>(pvArgs), reinterpret_cast<BA_ONDETECTPATCHTARGET_RESULTS*>(pvResults)); | ||
829 | break; | ||
830 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONDETECTMSIFEATURE: | ||
831 | hr = BalBaseBAProcOnDetectMsiFeature(pBA, reinterpret_cast<BA_ONDETECTMSIFEATURE_ARGS*>(pvArgs), reinterpret_cast<BA_ONDETECTMSIFEATURE_RESULTS*>(pvResults)); | ||
832 | break; | ||
833 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONDETECTPACKAGECOMPLETE: | ||
834 | hr = BalBaseBAProcOnDetectPackageComplete(pBA, reinterpret_cast<BA_ONDETECTPACKAGECOMPLETE_ARGS*>(pvArgs), reinterpret_cast<BA_ONDETECTPACKAGECOMPLETE_RESULTS*>(pvResults)); | ||
835 | break; | ||
836 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONPLANRELATEDBUNDLE: | ||
837 | hr = BalBaseBAProcOnPlanRelatedBundle(pBA, reinterpret_cast<BA_ONPLANRELATEDBUNDLE_ARGS*>(pvArgs), reinterpret_cast<BA_ONPLANRELATEDBUNDLE_RESULTS*>(pvResults)); | ||
838 | break; | ||
839 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONPLANPACKAGEBEGIN: | ||
840 | hr = BalBaseBAProcOnPlanPackageBegin(pBA, reinterpret_cast<BA_ONPLANPACKAGEBEGIN_ARGS*>(pvArgs), reinterpret_cast<BA_ONPLANPACKAGEBEGIN_RESULTS*>(pvResults)); | ||
841 | break; | ||
842 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONPLANPATCHTARGET: | ||
843 | hr = BalBaseBAProcOnPlanPatchTarget(pBA, reinterpret_cast<BA_ONPLANPATCHTARGET_ARGS*>(pvArgs), reinterpret_cast<BA_ONPLANPATCHTARGET_RESULTS*>(pvResults)); | ||
844 | break; | ||
845 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONPLANMSIFEATURE: | ||
846 | hr = BalBaseBAProcOnPlanMsiFeature(pBA, reinterpret_cast<BA_ONPLANMSIFEATURE_ARGS*>(pvArgs), reinterpret_cast<BA_ONPLANMSIFEATURE_RESULTS*>(pvResults)); | ||
847 | break; | ||
848 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONPLANPACKAGECOMPLETE: | ||
849 | hr = BalBaseBAProcOnPlanPackageComplete(pBA, reinterpret_cast<BA_ONPLANPACKAGECOMPLETE_ARGS*>(pvArgs), reinterpret_cast<BA_ONPLANPACKAGECOMPLETE_RESULTS*>(pvResults)); | ||
850 | break; | ||
851 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONAPPLYBEGIN: | ||
852 | hr = BalBaseBAProcOnApplyBegin(pBA, reinterpret_cast<BA_ONAPPLYBEGIN_ARGS*>(pvArgs), reinterpret_cast<BA_ONAPPLYBEGIN_RESULTS*>(pvResults)); | ||
853 | break; | ||
854 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONELEVATEBEGIN: | ||
855 | hr = BalBaseBAProcOnElevateBegin(pBA, reinterpret_cast<BA_ONELEVATEBEGIN_ARGS*>(pvArgs), reinterpret_cast<BA_ONELEVATEBEGIN_RESULTS*>(pvResults)); | ||
856 | break; | ||
857 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONELEVATECOMPLETE: | ||
858 | hr = BalBaseBAProcOnElevateComplete(pBA, reinterpret_cast<BA_ONELEVATECOMPLETE_ARGS*>(pvArgs), reinterpret_cast<BA_ONELEVATECOMPLETE_RESULTS*>(pvResults)); | ||
859 | break; | ||
860 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONPROGRESS: | ||
861 | hr = BalBaseBAProcOnProgress(pBA, reinterpret_cast<BA_ONPROGRESS_ARGS*>(pvArgs), reinterpret_cast<BA_ONPROGRESS_RESULTS*>(pvResults)); | ||
862 | break; | ||
863 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONERROR: | ||
864 | hr = BalBaseBAProcOnError(pBA, reinterpret_cast<BA_ONERROR_ARGS*>(pvArgs), reinterpret_cast<BA_ONERROR_RESULTS*>(pvResults)); | ||
865 | break; | ||
866 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONREGISTERBEGIN: | ||
867 | hr = BalBaseBAProcOnRegisterBegin(pBA, reinterpret_cast<BA_ONREGISTERBEGIN_ARGS*>(pvArgs), reinterpret_cast<BA_ONREGISTERBEGIN_RESULTS*>(pvResults)); | ||
868 | break; | ||
869 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONREGISTERCOMPLETE: | ||
870 | hr = BalBaseBAProcOnRegisterComplete(pBA, reinterpret_cast<BA_ONREGISTERCOMPLETE_ARGS*>(pvArgs), reinterpret_cast<BA_ONREGISTERCOMPLETE_RESULTS*>(pvResults)); | ||
871 | break; | ||
872 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONCACHEBEGIN: | ||
873 | hr = BalBaseBAProcOnCacheBegin(pBA, reinterpret_cast<BA_ONCACHEBEGIN_ARGS*>(pvArgs), reinterpret_cast<BA_ONCACHEBEGIN_RESULTS*>(pvResults)); | ||
874 | break; | ||
875 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONCACHEPACKAGEBEGIN: | ||
876 | hr = BalBaseBAProcOnCachePackageBegin(pBA, reinterpret_cast<BA_ONCACHEPACKAGEBEGIN_ARGS*>(pvArgs), reinterpret_cast<BA_ONCACHEPACKAGEBEGIN_RESULTS*>(pvResults)); | ||
877 | break; | ||
878 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONCACHEACQUIREBEGIN: | ||
879 | hr = BalBaseBAProcOnCacheAcquireBegin(pBA, reinterpret_cast<BA_ONCACHEACQUIREBEGIN_ARGS*>(pvArgs), reinterpret_cast<BA_ONCACHEACQUIREBEGIN_RESULTS*>(pvResults)); | ||
880 | break; | ||
881 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONCACHEACQUIREPROGRESS: | ||
882 | hr = BalBaseBAProcOnCacheAcquireProgress(pBA, reinterpret_cast<BA_ONCACHEACQUIREPROGRESS_ARGS*>(pvArgs), reinterpret_cast<BA_ONCACHEACQUIREPROGRESS_RESULTS*>(pvResults)); | ||
883 | break; | ||
884 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONCACHEACQUIRERESOLVING: | ||
885 | hr = BalBaseBAProcOnCacheAcquireResolving(pBA, reinterpret_cast<BA_ONCACHEACQUIRERESOLVING_ARGS*>(pvArgs), reinterpret_cast<BA_ONCACHEACQUIRERESOLVING_RESULTS*>(pvResults)); | ||
886 | break; | ||
887 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONCACHEACQUIRECOMPLETE: | ||
888 | hr = BalBaseBAProcOnCacheAcquireComplete(pBA, reinterpret_cast<BA_ONCACHEACQUIRECOMPLETE_ARGS*>(pvArgs), reinterpret_cast<BA_ONCACHEACQUIRECOMPLETE_RESULTS*>(pvResults)); | ||
889 | break; | ||
890 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONCACHEVERIFYBEGIN: | ||
891 | hr = BalBaseBAProcOnCacheVerifyBegin(pBA, reinterpret_cast<BA_ONCACHEVERIFYBEGIN_ARGS*>(pvArgs), reinterpret_cast<BA_ONCACHEVERIFYBEGIN_RESULTS*>(pvResults)); | ||
892 | break; | ||
893 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONCACHEVERIFYPROGRESS: | ||
894 | hr = BalBaseBAProcOnCacheVerifyProgress(pBA, reinterpret_cast<BA_ONCACHEVERIFYPROGRESS_ARGS*>(pvArgs), reinterpret_cast<BA_ONCACHEVERIFYPROGRESS_RESULTS*>(pvResults)); | ||
895 | break; | ||
896 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONCACHEVERIFYCOMPLETE: | ||
897 | hr = BalBaseBAProcOnCacheVerifyComplete(pBA, reinterpret_cast<BA_ONCACHEVERIFYCOMPLETE_ARGS*>(pvArgs), reinterpret_cast<BA_ONCACHEVERIFYCOMPLETE_RESULTS*>(pvResults)); | ||
898 | break; | ||
899 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONCACHEPACKAGECOMPLETE: | ||
900 | hr = BalBaseBAProcOnCachePackageComplete(pBA, reinterpret_cast<BA_ONCACHEPACKAGECOMPLETE_ARGS*>(pvArgs), reinterpret_cast<BA_ONCACHEPACKAGECOMPLETE_RESULTS*>(pvResults)); | ||
901 | break; | ||
902 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONCACHECOMPLETE: | ||
903 | hr = BalBaseBAProcOnCacheComplete(pBA, reinterpret_cast<BA_ONCACHECOMPLETE_ARGS*>(pvArgs), reinterpret_cast<BA_ONCACHECOMPLETE_RESULTS*>(pvResults)); | ||
904 | break; | ||
905 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONEXECUTEBEGIN: | ||
906 | hr = BalBaseBAProcOnExecuteBegin(pBA, reinterpret_cast<BA_ONEXECUTEBEGIN_ARGS*>(pvArgs), reinterpret_cast<BA_ONEXECUTEBEGIN_RESULTS*>(pvResults)); | ||
907 | break; | ||
908 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONEXECUTEPACKAGEBEGIN: | ||
909 | hr = BalBaseBAProcOnExecutePackageBegin(pBA, reinterpret_cast<BA_ONEXECUTEPACKAGEBEGIN_ARGS*>(pvArgs), reinterpret_cast<BA_ONEXECUTEPACKAGEBEGIN_RESULTS*>(pvResults)); | ||
910 | break; | ||
911 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONEXECUTEPATCHTARGET: | ||
912 | hr = BalBaseBAProcOnExecutePatchTarget(pBA, reinterpret_cast<BA_ONEXECUTEPATCHTARGET_ARGS*>(pvArgs), reinterpret_cast<BA_ONEXECUTEPATCHTARGET_RESULTS*>(pvResults)); | ||
913 | break; | ||
914 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONEXECUTEPROGRESS: | ||
915 | hr = BalBaseBAProcOnExecuteProgress(pBA, reinterpret_cast<BA_ONEXECUTEPROGRESS_ARGS*>(pvArgs), reinterpret_cast<BA_ONEXECUTEPROGRESS_RESULTS*>(pvResults)); | ||
916 | break; | ||
917 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONEXECUTEMSIMESSAGE: | ||
918 | hr = BalBaseBAProcOnExecuteMsiMessage(pBA, reinterpret_cast<BA_ONEXECUTEMSIMESSAGE_ARGS*>(pvArgs), reinterpret_cast<BA_ONEXECUTEMSIMESSAGE_RESULTS*>(pvResults)); | ||
919 | break; | ||
920 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONEXECUTEFILESINUSE: | ||
921 | hr = BalBaseBAProcOnExecuteFilesInUse(pBA, reinterpret_cast<BA_ONEXECUTEFILESINUSE_ARGS*>(pvArgs), reinterpret_cast<BA_ONEXECUTEFILESINUSE_RESULTS*>(pvResults)); | ||
922 | break; | ||
923 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONEXECUTEPACKAGECOMPLETE: | ||
924 | hr = BalBaseBAProcOnExecutePackageComplete(pBA, reinterpret_cast<BA_ONEXECUTEPACKAGECOMPLETE_ARGS*>(pvArgs), reinterpret_cast<BA_ONEXECUTEPACKAGECOMPLETE_RESULTS*>(pvResults)); | ||
925 | break; | ||
926 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONEXECUTECOMPLETE: | ||
927 | hr = BalBaseBAProcOnExecuteComplete(pBA, reinterpret_cast<BA_ONEXECUTECOMPLETE_ARGS*>(pvArgs), reinterpret_cast<BA_ONEXECUTECOMPLETE_RESULTS*>(pvResults)); | ||
928 | break; | ||
929 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONUNREGISTERBEGIN: | ||
930 | hr = BalBaseBAProcOnUnregisterBegin(pBA, reinterpret_cast<BA_ONUNREGISTERBEGIN_ARGS*>(pvArgs), reinterpret_cast<BA_ONUNREGISTERBEGIN_RESULTS*>(pvResults)); | ||
931 | break; | ||
932 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONUNREGISTERCOMPLETE: | ||
933 | hr = BalBaseBAProcOnUnregisterComplete(pBA, reinterpret_cast<BA_ONUNREGISTERCOMPLETE_ARGS*>(pvArgs), reinterpret_cast<BA_ONUNREGISTERCOMPLETE_RESULTS*>(pvResults)); | ||
934 | break; | ||
935 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONAPPLYCOMPLETE: | ||
936 | hr = BalBaseBAProcOnApplyComplete(pBA, reinterpret_cast<BA_ONAPPLYCOMPLETE_ARGS*>(pvArgs), reinterpret_cast<BA_ONAPPLYCOMPLETE_RESULTS*>(pvResults)); | ||
937 | break; | ||
938 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONLAUNCHAPPROVEDEXEBEGIN: | ||
939 | hr = BalBaseBAProcOnLaunchApprovedExeBegin(pBA, reinterpret_cast<BA_ONLAUNCHAPPROVEDEXEBEGIN_ARGS*>(pvArgs), reinterpret_cast<BA_ONLAUNCHAPPROVEDEXEBEGIN_RESULTS*>(pvResults)); | ||
940 | break; | ||
941 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONLAUNCHAPPROVEDEXECOMPLETE: | ||
942 | hr = BalBaseBAProcOnLaunchApprovedExeComplete(pBA, reinterpret_cast<BA_ONLAUNCHAPPROVEDEXECOMPLETE_ARGS*>(pvArgs), reinterpret_cast<BA_ONLAUNCHAPPROVEDEXECOMPLETE_RESULTS*>(pvResults)); | ||
943 | break; | ||
944 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONPLANMSIPACKAGE: | ||
945 | hr = BalBaseBAProcOnPlanMsiPackage(pBA, reinterpret_cast<BA_ONPLANMSIPACKAGE_ARGS*>(pvArgs), reinterpret_cast<BA_ONPLANMSIPACKAGE_RESULTS*>(pvResults)); | ||
946 | break; | ||
947 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONBEGINMSITRANSACTIONBEGIN: | ||
948 | hr = BalBaseBAProcOnBeginMsiTransactionBegin(pBA, reinterpret_cast<BA_ONBEGINMSITRANSACTIONBEGIN_ARGS*>(pvArgs), reinterpret_cast<BA_ONBEGINMSITRANSACTIONBEGIN_RESULTS*>(pvResults)); | ||
949 | break; | ||
950 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONBEGINMSITRANSACTIONCOMPLETE: | ||
951 | hr = BalBaseBAProcOnBeginMsiTransactionComplete(pBA, reinterpret_cast<BA_ONBEGINMSITRANSACTIONCOMPLETE_ARGS*>(pvArgs), reinterpret_cast<BA_ONBEGINMSITRANSACTIONCOMPLETE_RESULTS*>(pvResults)); | ||
952 | break; | ||
953 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONCOMMITMSITRANSACTIONBEGIN: | ||
954 | hr = BalBaseBAProcOnCommitMsiTransactionBegin(pBA, reinterpret_cast<BA_ONCOMMITMSITRANSACTIONBEGIN_ARGS*>(pvArgs), reinterpret_cast<BA_ONCOMMITMSITRANSACTIONBEGIN_RESULTS*>(pvResults)); | ||
955 | break; | ||
956 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONCOMMITMSITRANSACTIONCOMPLETE: | ||
957 | hr = BalBaseBAProcOnCommitMsiTransactionComplete(pBA, reinterpret_cast<BA_ONCOMMITMSITRANSACTIONCOMPLETE_ARGS*>(pvArgs), reinterpret_cast<BA_ONCOMMITMSITRANSACTIONCOMPLETE_RESULTS*>(pvResults)); | ||
958 | break; | ||
959 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONROLLBACKMSITRANSACTIONBEGIN: | ||
960 | hr = BalBaseBAProcOnRollbackMsiTransactionBegin(pBA, reinterpret_cast<BA_ONROLLBACKMSITRANSACTIONBEGIN_ARGS*>(pvArgs), reinterpret_cast<BA_ONROLLBACKMSITRANSACTIONBEGIN_RESULTS*>(pvResults)); | ||
961 | break; | ||
962 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONROLLBACKMSITRANSACTIONCOMPLETE: | ||
963 | hr = BalBaseBAProcOnRollbackMsiTransactionComplete(pBA, reinterpret_cast<BA_ONROLLBACKMSITRANSACTIONCOMPLETE_ARGS*>(pvArgs), reinterpret_cast<BA_ONROLLBACKMSITRANSACTIONCOMPLETE_RESULTS*>(pvResults)); | ||
964 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONPAUSEAUTOMATICUPDATESBEGIN: | ||
965 | hr = BalBaseBAProcOnPauseAutomaticUpdatesBegin(pBA, reinterpret_cast<BA_ONPAUSEAUTOMATICUPDATESBEGIN_ARGS*>(pvArgs), reinterpret_cast<BA_ONPAUSEAUTOMATICUPDATESBEGIN_RESULTS*>(pvResults)); | ||
966 | break; | ||
967 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONPAUSEAUTOMATICUPDATESCOMPLETE: | ||
968 | hr = BalBaseBAProcOnPauseAutomaticUpdatesComplete(pBA, reinterpret_cast<BA_ONPAUSEAUTOMATICUPDATESCOMPLETE_ARGS*>(pvArgs), reinterpret_cast<BA_ONPAUSEAUTOMATICUPDATESCOMPLETE_RESULTS*>(pvResults)); | ||
969 | break; | ||
970 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONSYSTEMRESTOREPOINTBEGIN: | ||
971 | hr = BalBaseBAProcOnSystemRestorePointBegin(pBA, reinterpret_cast<BA_ONSYSTEMRESTOREPOINTBEGIN_ARGS*>(pvArgs), reinterpret_cast<BA_ONSYSTEMRESTOREPOINTBEGIN_RESULTS*>(pvResults)); | ||
972 | break; | ||
973 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONSYSTEMRESTOREPOINTCOMPLETE: | ||
974 | hr = BalBaseBAProcOnSystemRestorePointComplete(pBA, reinterpret_cast<BA_ONSYSTEMRESTOREPOINTCOMPLETE_ARGS*>(pvArgs), reinterpret_cast<BA_ONSYSTEMRESTOREPOINTCOMPLETE_RESULTS*>(pvResults)); | ||
975 | break; | ||
976 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONPLANNEDPACKAGE: | ||
977 | hr = BalBaseBAProcOnPlannedPackage(pBA, reinterpret_cast<BA_ONPLANNEDPACKAGE_ARGS*>(pvArgs), reinterpret_cast<BA_ONPLANNEDPACKAGE_RESULTS*>(pvResults)); | ||
978 | break; | ||
979 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONPLANFORWARDCOMPATIBLEBUNDLE: | ||
980 | hr = BalBaseBAProcOnPlanForwardCompatibleBundle(pBA, reinterpret_cast<BA_ONPLANFORWARDCOMPATIBLEBUNDLE_ARGS*>(pvArgs), reinterpret_cast<BA_ONPLANFORWARDCOMPATIBLEBUNDLE_RESULTS*>(pvResults)); | ||
981 | break; | ||
982 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONCACHECONTAINERORPAYLOADVERIFYBEGIN: | ||
983 | hr = BalBaseBAProcOnCacheContainerOrPayloadVerifyBegin(pBA, reinterpret_cast<BA_ONCACHECONTAINERORPAYLOADVERIFYBEGIN_ARGS*>(pvArgs), reinterpret_cast<BA_ONCACHECONTAINERORPAYLOADVERIFYBEGIN_RESULTS*>(pvResults)); | ||
984 | break; | ||
985 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONCACHECONTAINERORPAYLOADVERIFYPROGRESS: | ||
986 | hr = BalBaseBAProcOnCacheContainerOrPayloadVerifyProgress(pBA, reinterpret_cast<BA_ONCACHECONTAINERORPAYLOADVERIFYPROGRESS_ARGS*>(pvArgs), reinterpret_cast<BA_ONCACHECONTAINERORPAYLOADVERIFYPROGRESS_RESULTS*>(pvResults)); | ||
987 | break; | ||
988 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONCACHECONTAINERORPAYLOADVERIFYCOMPLETE: | ||
989 | hr = BalBaseBAProcOnCacheContainerOrPayloadVerifyComplete(pBA, reinterpret_cast<BA_ONCACHECONTAINERORPAYLOADVERIFYCOMPLETE_ARGS*>(pvArgs), reinterpret_cast<BA_ONCACHECONTAINERORPAYLOADVERIFYCOMPLETE_RESULTS*>(pvResults)); | ||
990 | break; | ||
991 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONCACHEPAYLOADEXTRACTBEGIN: | ||
992 | hr = BalBaseBAProcOnCachePayloadExtractBegin(pBA, reinterpret_cast<BA_ONCACHEPAYLOADEXTRACTBEGIN_ARGS*>(pvArgs), reinterpret_cast<BA_ONCACHEPAYLOADEXTRACTBEGIN_RESULTS*>(pvResults)); | ||
993 | break; | ||
994 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONCACHEPAYLOADEXTRACTPROGRESS: | ||
995 | hr = BalBaseBAProcOnCachePayloadExtractProgress(pBA, reinterpret_cast<BA_ONCACHEPAYLOADEXTRACTPROGRESS_ARGS*>(pvArgs), reinterpret_cast<BA_ONCACHEPAYLOADEXTRACTPROGRESS_RESULTS*>(pvResults)); | ||
996 | break; | ||
997 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONCACHEPAYLOADEXTRACTCOMPLETE: | ||
998 | hr = BalBaseBAProcOnCachePayloadExtractComplete(pBA, reinterpret_cast<BA_ONCACHEPAYLOADEXTRACTCOMPLETE_ARGS*>(pvArgs), reinterpret_cast<BA_ONCACHEPAYLOADEXTRACTCOMPLETE_RESULTS*>(pvResults)); | ||
999 | break; | ||
1000 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONPLANROLLBACKBOUNDARY: | ||
1001 | hr = BalBaseBAProcOnPlanRollbackBoundary(pBA, reinterpret_cast<BA_ONPLANROLLBACKBOUNDARY_ARGS*>(pvArgs), reinterpret_cast<BA_ONPLANROLLBACKBOUNDARY_RESULTS*>(pvResults)); | ||
1002 | break; | ||
1003 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONSETUPDATEBEGIN: | ||
1004 | hr = BalBaseBAProcOnSetUpdateBegin(pBA, reinterpret_cast<BA_ONSETUPDATEBEGIN_ARGS*>(pvArgs), reinterpret_cast<BA_ONSETUPDATEBEGIN_RESULTS*>(pvResults)); | ||
1005 | break; | ||
1006 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONSETUPDATECOMPLETE: | ||
1007 | hr = BalBaseBAProcOnSetUpdateComplete(pBA, reinterpret_cast<BA_ONSETUPDATECOMPLETE_ARGS*>(pvArgs), reinterpret_cast<BA_ONSETUPDATECOMPLETE_RESULTS*>(pvResults)); | ||
1008 | break; | ||
1009 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONDETECTCOMPATIBLEMSIPACKAGE: | ||
1010 | hr = BalBaseBAProcOnDetectCompatiblePackage(pBA, reinterpret_cast<BA_ONDETECTCOMPATIBLEMSIPACKAGE_ARGS*>(pvArgs), reinterpret_cast<BA_ONDETECTCOMPATIBLEMSIPACKAGE_RESULTS*>(pvResults)); | ||
1011 | break; | ||
1012 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONPLANCOMPATIBLEMSIPACKAGEBEGIN: | ||
1013 | hr = BalBaseBAProcOnPlanCompatibleMsiPackageBegin(pBA, reinterpret_cast<BA_ONPLANCOMPATIBLEMSIPACKAGEBEGIN_ARGS*>(pvArgs), reinterpret_cast<BA_ONPLANCOMPATIBLEMSIPACKAGEBEGIN_RESULTS*>(pvResults)); | ||
1014 | break; | ||
1015 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONPLANCOMPATIBLEMSIPACKAGECOMPLETE: | ||
1016 | hr = BalBaseBAProcOnPlanCompatibleMsiPackageComplete(pBA, reinterpret_cast<BA_ONPLANCOMPATIBLEMSIPACKAGECOMPLETE_ARGS*>(pvArgs), reinterpret_cast<BA_ONPLANCOMPATIBLEMSIPACKAGECOMPLETE_RESULTS*>(pvResults)); | ||
1017 | break; | ||
1018 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONPLANNEDCOMPATIBLEPACKAGE: | ||
1019 | hr = BalBaseBAProcOnPlannedCompatiblePackage(pBA, reinterpret_cast<BA_ONPLANNEDCOMPATIBLEPACKAGE_ARGS*>(pvArgs), reinterpret_cast<BA_ONPLANNEDCOMPATIBLEPACKAGE_RESULTS*>(pvResults)); | ||
1020 | break; | ||
1021 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONPLANRESTORERELATEDBUNDLE: | ||
1022 | hr = BalBaseBAProcOnPlanRestoreRelatedBundle(pBA, reinterpret_cast<BA_ONPLANRESTORERELATEDBUNDLE_ARGS*>(pvArgs), reinterpret_cast<BA_ONPLANRESTORERELATEDBUNDLE_RESULTS*>(pvResults)); | ||
1023 | break; | ||
1024 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONPLANRELATEDBUNDLETYPE: | ||
1025 | hr = BalBaseBAProcOnPlanRelatedBundleType(pBA, reinterpret_cast<BA_ONPLANRELATEDBUNDLETYPE_ARGS*>(pvArgs), reinterpret_cast<BA_ONPLANRELATEDBUNDLETYPE_RESULTS*>(pvResults)); | ||
1026 | break; | ||
1027 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONAPPLYDOWNGRADE: | ||
1028 | hr = BalBaseBAProcOnApplyDowngrade(pBA, reinterpret_cast<BA_ONAPPLYDOWNGRADE_ARGS*>(pvArgs), reinterpret_cast<BA_ONAPPLYDOWNGRADE_RESULTS*>(pvResults)); | ||
1029 | break; | ||
1030 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONEXECUTEPROCESSCANCEL: | ||
1031 | hr = BalBaseBAProcOnExecuteProcessCancel(pBA, reinterpret_cast<BA_ONEXECUTEPROCESSCANCEL_ARGS*>(pvArgs), reinterpret_cast<BA_ONEXECUTEPROCESSCANCEL_RESULTS*>(pvResults)); | ||
1032 | break; | ||
1033 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONDETECTRELATEDBUNDLEPACKAGE: | ||
1034 | hr = BalBaseBAProcOnDetectRelatedBundlePackage(pBA, reinterpret_cast<BA_ONDETECTRELATEDBUNDLEPACKAGE_ARGS*>(pvArgs), reinterpret_cast<BA_ONDETECTRELATEDBUNDLEPACKAGE_RESULTS*>(pvResults)); | ||
1035 | break; | ||
1036 | case BOOTSTRAPPER_APPLICATION_MESSAGE_ONCACHEPACKAGENONVITALVALIDATIONFAILURE: | ||
1037 | hr = BalBaseBAProcOnCachePackageNonVitalValidationFailure(pBA, reinterpret_cast<BA_ONCACHEPACKAGENONVITALVALIDATIONFAILURE_ARGS*>(pvArgs), reinterpret_cast<BA_ONCACHEPACKAGENONVITALVALIDATIONFAILURE_RESULTS*>(pvResults)); | ||
1038 | break; | ||
1039 | } | ||
1040 | } | ||
1041 | |||
1042 | pBA->BAProcFallback(message, pvArgs, pvResults, &hr, pvContext); | ||
1043 | |||
1044 | return hr; | ||
1045 | } | ||
diff --git a/src/api/burn/balutil/inc/BalBootstrapperEngine.h b/src/api/burn/balutil/inc/BalBootstrapperEngine.h deleted file mode 100644 index 45131d98..00000000 --- a/src/api/burn/balutil/inc/BalBootstrapperEngine.h +++ /dev/null | |||
@@ -1,17 +0,0 @@ | |||
1 | // Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. | ||
2 | |||
3 | #ifdef __cplusplus | ||
4 | extern "C" { | ||
5 | #endif | ||
6 | |||
7 | // function declarations | ||
8 | |||
9 | HRESULT BalBootstrapperEngineCreate( | ||
10 | __in PFN_BOOTSTRAPPER_ENGINE_PROC pfnBAEngineProc, | ||
11 | __in_opt LPVOID pvBAEngineProcContext, | ||
12 | __out IBootstrapperEngine** ppEngineForApplication | ||
13 | ); | ||
14 | |||
15 | #ifdef __cplusplus | ||
16 | } | ||
17 | #endif | ||
diff --git a/src/api/burn/balutil/inc/IBAFunctions.h b/src/api/burn/balutil/inc/IBAFunctions.h index bb911040..b0afabb3 100644 --- a/src/api/burn/balutil/inc/IBAFunctions.h +++ b/src/api/burn/balutil/inc/IBAFunctions.h | |||
@@ -2,6 +2,8 @@ | |||
2 | // Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. | 2 | // Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. |
3 | 3 | ||
4 | 4 | ||
5 | #include "IBootstrapperApplication.h" | ||
6 | |||
5 | DECLARE_INTERFACE_IID_(IBAFunctions, IBootstrapperApplication, "0FB445ED-17BD-49C7-BE19-479776F8AE96") | 7 | DECLARE_INTERFACE_IID_(IBAFunctions, IBootstrapperApplication, "0FB445ED-17BD-49C7-BE19-479776F8AE96") |
6 | { | 8 | { |
7 | // OnThemeLoaded - Called after the BA finished loading all the controls for the theme. | 9 | // OnThemeLoaded - Called after the BA finished loading all the controls for the theme. |
diff --git a/src/api/burn/balutil/inc/IBootstrapperApplication.h b/src/api/burn/balutil/inc/IBootstrapperApplication.h index faa211e4..6eb32ee6 100644 --- a/src/api/burn/balutil/inc/IBootstrapperApplication.h +++ b/src/api/burn/balutil/inc/IBootstrapperApplication.h | |||
@@ -1,6 +1,8 @@ | |||
1 | #pragma once | 1 | #pragma once |
2 | // Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. | 2 | // Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. |
3 | 3 | ||
4 | #include <batypes.h> | ||
5 | |||
4 | 6 | ||
5 | DECLARE_INTERFACE_IID_(IBootstrapperApplication, IUnknown, "53C31D56-49C0-426B-AB06-099D717C67FE") | 7 | DECLARE_INTERFACE_IID_(IBootstrapperApplication, IUnknown, "53C31D56-49C0-426B-AB06-099D717C67FE") |
6 | { | 8 | { |
@@ -9,8 +11,7 @@ DECLARE_INTERFACE_IID_(IBootstrapperApplication, IUnknown, "53C31D56-49C0-426B-A | |||
9 | STDMETHOD(BAProc)( | 11 | STDMETHOD(BAProc)( |
10 | __in BOOTSTRAPPER_APPLICATION_MESSAGE message, | 12 | __in BOOTSTRAPPER_APPLICATION_MESSAGE message, |
11 | __in const LPVOID pvArgs, | 13 | __in const LPVOID pvArgs, |
12 | __inout LPVOID pvResults, | 14 | __inout LPVOID pvResults |
13 | __in_opt LPVOID pvContext | ||
14 | ) = 0; | 15 | ) = 0; |
15 | 16 | ||
16 | // BAProcFallback - The PFN_BOOTSTRAPPER_APPLICATION_PROC can call this method | 17 | // BAProcFallback - The PFN_BOOTSTRAPPER_APPLICATION_PROC can call this method |
@@ -20,10 +21,22 @@ DECLARE_INTERFACE_IID_(IBootstrapperApplication, IUnknown, "53C31D56-49C0-426B-A | |||
20 | __in BOOTSTRAPPER_APPLICATION_MESSAGE message, | 21 | __in BOOTSTRAPPER_APPLICATION_MESSAGE message, |
21 | __in const LPVOID pvArgs, | 22 | __in const LPVOID pvArgs, |
22 | __inout LPVOID pvResults, | 23 | __inout LPVOID pvResults, |
23 | __inout HRESULT* phr, | 24 | __inout HRESULT* phr |
24 | __in_opt LPVOID pvContext | 25 | ) = 0; |
26 | |||
27 | // OnCreate - called when the bootstrapper application is created. | ||
28 | // | ||
29 | virtual STDMETHODIMP OnCreate( | ||
30 | __in IBootstrapperEngine* pEngine, | ||
31 | __in BOOTSTRAPPER_COMMAND* pCommand | ||
25 | ) = 0; | 32 | ) = 0; |
26 | 33 | ||
34 | // OnDestroy - called before the bootstrapper application stops. | ||
35 | // | ||
36 | STDMETHOD(OnDestroy)( | ||
37 | __in BOOL fReload | ||
38 | ) = 0; | ||
39 | |||
27 | // OnStartup - called when the engine is ready for the bootstrapper application to start. | 40 | // OnStartup - called when the engine is ready for the bootstrapper application to start. |
28 | // | 41 | // |
29 | STDMETHOD(OnStartup)() = 0; | 42 | STDMETHOD(OnStartup)() = 0; |
@@ -688,14 +701,6 @@ DECLARE_INTERFACE_IID_(IBootstrapperApplication, IUnknown, "53C31D56-49C0-426B-A | |||
688 | __in HRESULT hrStatus | 701 | __in HRESULT hrStatus |
689 | ) = 0; | 702 | ) = 0; |
690 | 703 | ||
691 | STDMETHOD(OnSetUpdateBegin)() = 0; | ||
692 | |||
693 | STDMETHOD(OnSetUpdateComplete)( | ||
694 | __in HRESULT hrStatus, | ||
695 | __in_z_opt LPCWSTR wzPreviousPackageId, | ||
696 | __in_z_opt LPCWSTR wzNewPackageId | ||
697 | ) = 0; | ||
698 | |||
699 | // OnPlanRestoreRelatedBundle - called when the engine begins planning an upgrade related bundle for restoring in case of failure. | 704 | // OnPlanRestoreRelatedBundle - called when the engine begins planning an upgrade related bundle for restoring in case of failure. |
700 | STDMETHOD(OnPlanRestoreRelatedBundle)( | 705 | STDMETHOD(OnPlanRestoreRelatedBundle)( |
701 | __in_z LPCWSTR wzBundleId, | 706 | __in_z LPCWSTR wzBundleId, |
diff --git a/src/api/burn/balutil/inc/IBootstrapperApplicationFactory.h b/src/api/burn/balutil/inc/IBootstrapperApplicationFactory.h deleted file mode 100644 index fd603e50..00000000 --- a/src/api/burn/balutil/inc/IBootstrapperApplicationFactory.h +++ /dev/null | |||
@@ -1,13 +0,0 @@ | |||
1 | #pragma once | ||
2 | // Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. | ||
3 | |||
4 | |||
5 | #include "precomp.h" | ||
6 | |||
7 | DECLARE_INTERFACE_IID_(IBootstrapperApplicationFactory, IUnknown, "2965A12F-AC7B-43A0-85DF-E4B2168478A4") | ||
8 | { | ||
9 | STDMETHOD(Create)( | ||
10 | __in const BOOTSTRAPPER_CREATE_ARGS* pArgs, | ||
11 | __inout BOOTSTRAPPER_CREATE_RESULTS *pResults | ||
12 | ); | ||
13 | }; | ||
diff --git a/src/api/burn/balutil/inc/IBootstrapperEngine.h b/src/api/burn/balutil/inc/IBootstrapperEngine.h index bfa13997..3c1afb77 100644 --- a/src/api/burn/balutil/inc/IBootstrapperEngine.h +++ b/src/api/burn/balutil/inc/IBootstrapperEngine.h | |||
@@ -1,6 +1,7 @@ | |||
1 | #pragma once | 1 | #pragma once |
2 | // Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. | 2 | // Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. |
3 | 3 | ||
4 | #include <baenginetypes.h> | ||
4 | 5 | ||
5 | DECLARE_INTERFACE_IID_(IBootstrapperEngine, IUnknown, "6480D616-27A0-44D7-905B-81512C29C2FB") | 6 | DECLARE_INTERFACE_IID_(IBootstrapperEngine, IUnknown, "6480D616-27A0-44D7-905B-81512C29C2FB") |
6 | { | 7 | { |
@@ -65,7 +66,8 @@ DECLARE_INTERFACE_IID_(IBootstrapperEngine, IUnknown, "6480D616-27A0-44D7-905B-8 | |||
65 | __in_z_opt LPCWSTR wzDownloadSource, | 66 | __in_z_opt LPCWSTR wzDownloadSource, |
66 | __in DWORD64 qwSize, | 67 | __in DWORD64 qwSize, |
67 | __in BOOTSTRAPPER_UPDATE_HASH_TYPE hashType, | 68 | __in BOOTSTRAPPER_UPDATE_HASH_TYPE hashType, |
68 | __in_z_opt LPCWSTR wzHash | 69 | __in_z_opt LPCWSTR wzHash, |
70 | __in_z_opt LPCWSTR wzUpdatePackageId | ||
69 | ) = 0; | 71 | ) = 0; |
70 | 72 | ||
71 | STDMETHOD(SetLocalSource)( | 73 | STDMETHOD(SetLocalSource)( |
@@ -79,7 +81,8 @@ DECLARE_INTERFACE_IID_(IBootstrapperEngine, IUnknown, "6480D616-27A0-44D7-905B-8 | |||
79 | __in_z_opt LPCWSTR wzPayloadId, | 81 | __in_z_opt LPCWSTR wzPayloadId, |
80 | __in_z LPCWSTR wzUrl, | 82 | __in_z LPCWSTR wzUrl, |
81 | __in_z_opt LPCWSTR wzUser, | 83 | __in_z_opt LPCWSTR wzUser, |
82 | __in_z_opt LPCWSTR wzPassword | 84 | __in_z_opt LPCWSTR wzPassword, |
85 | __in_z_opt LPCWSTR wzAuthorizationHeader | ||
83 | ) = 0; | 86 | ) = 0; |
84 | 87 | ||
85 | STDMETHOD(SetVariableNumeric)( | 88 | STDMETHOD(SetVariableNumeric)( |
@@ -128,7 +131,8 @@ DECLARE_INTERFACE_IID_(IBootstrapperEngine, IUnknown, "6480D616-27A0-44D7-905B-8 | |||
128 | ) = 0; | 131 | ) = 0; |
129 | 132 | ||
130 | STDMETHOD(SetUpdateSource)( | 133 | STDMETHOD(SetUpdateSource)( |
131 | __in_z LPCWSTR wzUrl | 134 | __in_z LPCWSTR wzUrl, |
135 | __in_z_opt LPCWSTR wzAuthorizationHeader | ||
132 | ) = 0; | 136 | ) = 0; |
133 | 137 | ||
134 | STDMETHOD(CompareVersions)( | 138 | STDMETHOD(CompareVersions)( |
@@ -143,5 +147,4 @@ DECLARE_INTERFACE_IID_(IBootstrapperEngine, IUnknown, "6480D616-27A0-44D7-905B-8 | |||
143 | __out_ecount_opt(*pcchValue) LPWSTR wzValue, | 147 | __out_ecount_opt(*pcchValue) LPWSTR wzValue, |
144 | __inout SIZE_T* pcchValue | 148 | __inout SIZE_T* pcchValue |
145 | ) = 0; | 149 | ) = 0; |
146 | |||
147 | }; | 150 | }; |
diff --git a/src/api/burn/balutil/inc/balinfo.h b/src/api/burn/balutil/inc/balinfo.h index 7c607c44..234284f6 100644 --- a/src/api/burn/balutil/inc/balinfo.h +++ b/src/api/burn/balutil/inc/balinfo.h | |||
@@ -152,7 +152,6 @@ DAPI_(HRESULT) BalInfoAddRelatedBundleAsPackage( | |||
152 | DAPI_(HRESULT) BalInfoAddUpdateBundleAsPackage( | 152 | DAPI_(HRESULT) BalInfoAddUpdateBundleAsPackage( |
153 | __in BAL_INFO_PACKAGES* pPackages, | 153 | __in BAL_INFO_PACKAGES* pPackages, |
154 | __in_z LPCWSTR wzId, | 154 | __in_z LPCWSTR wzId, |
155 | __in_z LPCWSTR wzPreviousId, | ||
156 | __out_opt BAL_INFO_PACKAGE** ppPackage | 155 | __out_opt BAL_INFO_PACKAGE** ppPackage |
157 | ); | 156 | ); |
158 | 157 | ||
diff --git a/src/api/burn/balutil/inc/balutil.h b/src/api/burn/balutil/inc/balutil.h index 36c165a3..4f8cb23d 100644 --- a/src/api/burn/balutil/inc/balutil.h +++ b/src/api/burn/balutil/inc/balutil.h | |||
@@ -39,28 +39,34 @@ const LPCWSTR BAL_MANIFEST_FILENAME = L"BootstrapperApplicationData.xml"; | |||
39 | 39 | ||
40 | static const HRESULT E_WIXSTDBA_CONDITION_FAILED = MAKE_HRESULT(SEVERITY_ERROR, FACILITY_WIX, 1); | 40 | static const HRESULT E_WIXSTDBA_CONDITION_FAILED = MAKE_HRESULT(SEVERITY_ERROR, FACILITY_WIX, 1); |
41 | 41 | ||
42 | static const HRESULT E_MBAHOST_NET452_ON_WIN7RTM = MAKE_HRESULT(SEVERITY_ERROR, FACILITY_WIX, 1000); | ||
43 | static const HRESULT E_DNCHOST_SCD_RUNTIME_FAILURE = MAKE_HRESULT(SEVERITY_ERROR, FACILITY_WIX, 1001); | ||
44 | static const HRESULT E_PREREQBA_INFINITE_LOOP = MAKE_HRESULT(SEVERITY_ERROR, FACILITY_WIX, 1002); | 42 | static const HRESULT E_PREREQBA_INFINITE_LOOP = MAKE_HRESULT(SEVERITY_ERROR, FACILITY_WIX, 1002); |
45 | 43 | ||
46 | 44 | ||
47 | /******************************************************************* | 45 | /******************************************************************* |
48 | BalInitialize - remembers the engine interface to enable logging and | 46 | BootstrapperApplicationDebuggerCheck - allows bootstrapper application to |
49 | other functions. | 47 | explicitly check whether a debugger should be attached to the boostrapper |
48 | application. | ||
50 | 49 | ||
50 | Note: Automatically called in BootstrapperApplicationRun(). | ||
51 | ********************************************************************/ | 51 | ********************************************************************/ |
52 | DAPI_(void) BalInitialize( | 52 | DAPI_(VOID) BootstrapperApplicationDebuggerCheck(); |
53 | __in IBootstrapperEngine* pEngine | 53 | |
54 | /******************************************************************* | ||
55 | BootstrapperApplicationRun - runs the IBootstrapperApplication until | ||
56 | the application quits. | ||
57 | |||
58 | ********************************************************************/ | ||
59 | DAPI_(HRESULT) BootstrapperApplicationRun( | ||
60 | __in IBootstrapperApplication* pApplication | ||
54 | ); | 61 | ); |
55 | 62 | ||
56 | /******************************************************************* | 63 | /******************************************************************* |
57 | BalInitializeFromCreateArgs - convenience function to call BalBootstrapperEngineCreate | 64 | BalInitialize - remembers the engine interface to enable logging and |
58 | then pass it along to BalInitialize. | 65 | other functions. |
59 | 66 | ||
60 | ********************************************************************/ | 67 | ********************************************************************/ |
61 | DAPI_(HRESULT) BalInitializeFromCreateArgs( | 68 | DAPI_(void) BalInitialize( |
62 | __in const BOOTSTRAPPER_CREATE_ARGS* pArgs, | 69 | __in IBootstrapperEngine* pEngine |
63 | __out_opt IBootstrapperEngine** ppEngine | ||
64 | ); | 70 | ); |
65 | 71 | ||
66 | /******************************************************************* | 72 | /******************************************************************* |
@@ -292,7 +298,7 @@ DAPI_(HRESULT) BalLogErrorArgs( | |||
292 | ); | 298 | ); |
293 | 299 | ||
294 | /******************************************************************* | 300 | /******************************************************************* |
295 | BalLogId - logs a message with the engine with a string embedded in a | 301 | BalLogId - logs a message with the engine with a string embedded in a |
296 | MESSAGETABLE resource. | 302 | MESSAGETABLE resource. |
297 | 303 | ||
298 | ********************************************************************/ | 304 | ********************************************************************/ |