| 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 | #define TraceLog(x, s, ...) ExitTraceSource(BURN_SOURCE_DEFAULT, x, s, __VA_ARGS__) |
| 5 | |
| 6 | |
| 7 | #if defined(__cplusplus) |
| 8 | extern "C" { |
| 9 | #endif |
| 10 | |
| 11 | // constants |
| 12 | |
| 13 | enum WM_BURN |
| 14 | { |
| 15 | WM_BURN_FIRST = WM_APP + 0xFFF, // this enum value must always be first. |
| 16 | |
| 17 | WM_BURN_DETECT, |
| 18 | WM_BURN_PLAN, |
| 19 | WM_BURN_ELEVATE, |
| 20 | WM_BURN_APPLY, |
| 21 | WM_BURN_LAUNCH_APPROVED_EXE, |
| 22 | WM_BURN_QUIT, |
| 23 | |
| 24 | WM_BURN_LAST, // this enum value must always be last. |
| 25 | }; |
| 26 | |
| 27 | // forward declare |
| 28 | |
| 29 | enum BURN_MODE; |
| 30 | typedef struct _BAENGINE_CONTEXT BAENGINE_CONTEXT; |
| 31 | typedef struct _BAENGINE_ACTION BAENGINE_ACTION; |
| 32 | typedef struct _BURN_CACHE BURN_CACHE; |
| 33 | typedef struct _BURN_DEPENDENCIES BURN_DEPENDENCIES; |
| 34 | typedef struct _BURN_ENGINE_STATE BURN_ENGINE_STATE; |
| 35 | typedef struct _BURN_ENGINE_COMMAND BURN_ENGINE_COMMAND; |
| 36 | typedef struct _BURN_LOGGING BURN_LOGGING; |
| 37 | typedef struct _BURN_PACKAGES BURN_PACKAGES; |
| 38 | |
| 39 | |
| 40 | // typedefs |
| 41 | |
| 42 | typedef BOOL (WINAPI *PFN_INITIATESYSTEMSHUTDOWNEXW)( |
| 43 | __in_opt LPWSTR lpMachineName, |
| 44 | __in_opt LPWSTR lpMessage, |
| 45 | __in DWORD dwTimeout, |
| 46 | __in BOOL bForceAppsClosed, |
| 47 | __in BOOL bRebootAfterShutdown, |
| 48 | __in DWORD dwReason |
| 49 | ); |
| 50 | |
| 51 | |
| 52 | // variable declarations |
| 53 | |
| 54 | extern PFN_INITIATESYSTEMSHUTDOWNEXW vpfnInitiateSystemShutdownExW; |
| 55 | |
| 56 | |
| 57 | // function declarations |
| 58 | |
| 59 | void PlatformInitialize(); |
| 60 | |
| 61 | |
| 62 | #if defined(__cplusplus) |
| 63 | } |
| 64 | #endif |