aboutsummaryrefslogtreecommitdiff
path: root/src/WixToolset.Mba.Core/IBootstrapperApplicationFactory.cs
diff options
context:
space:
mode:
authorSean Hall <r.sean.hall@gmail.com>2019-12-22 10:31:33 +1100
committerSean Hall <r.sean.hall@gmail.com>2019-12-22 13:19:29 +1000
commit24379873f589cff33965f1104041f61c0c4503e0 (patch)
treeb50fb0270d2de706cb6f3a4dea0af77ce2cae9e1 /src/WixToolset.Mba.Core/IBootstrapperApplicationFactory.cs
parentf3c383c2412e376353d64a8b744184fa1cee1c6e (diff)
downloadwix-24379873f589cff33965f1104041f61c0c4503e0.tar.gz
wix-24379873f589cff33965f1104041f61c0c4503e0.tar.bz2
wix-24379873f589cff33965f1104041f61c0c4503e0.zip
Move the responsibility of wrapping the binary interfaces from mbahost to the new mbanative dll of WixToolset.Mba.Core.
Diffstat (limited to 'src/WixToolset.Mba.Core/IBootstrapperApplicationFactory.cs')
-rw-r--r--src/WixToolset.Mba.Core/IBootstrapperApplicationFactory.cs28
1 files changed, 25 insertions, 3 deletions
diff --git a/src/WixToolset.Mba.Core/IBootstrapperApplicationFactory.cs b/src/WixToolset.Mba.Core/IBootstrapperApplicationFactory.cs
index f5d4c705..700f0888 100644
--- a/src/WixToolset.Mba.Core/IBootstrapperApplicationFactory.cs
+++ b/src/WixToolset.Mba.Core/IBootstrapperApplicationFactory.cs
@@ -12,9 +12,9 @@ namespace WixToolset.Mba.Core
12 [GeneratedCodeAttribute("WixToolset.Bootstrapper.InteropCodeGenerator", "1.0.0.0")] 12 [GeneratedCodeAttribute("WixToolset.Bootstrapper.InteropCodeGenerator", "1.0.0.0")]
13 public interface IBootstrapperApplicationFactory 13 public interface IBootstrapperApplicationFactory
14 { 14 {
15 IBootstrapperApplication Create( 15 void Create(
16 [MarshalAs(UnmanagedType.Interface)] IBootstrapperEngine pEngine, 16 IntPtr pArgs,
17 ref Command command 17 IntPtr pResults
18 ); 18 );
19 } 19 }
20 20
@@ -23,6 +23,7 @@ namespace WixToolset.Mba.Core
23 [GeneratedCodeAttribute("WixToolset.Bootstrapper.InteropCodeGenerator", "1.0.0.0")] 23 [GeneratedCodeAttribute("WixToolset.Bootstrapper.InteropCodeGenerator", "1.0.0.0")]
24 public struct Command 24 public struct Command
25 { 25 {
26 [MarshalAs(UnmanagedType.I4)] internal int cbSize;
26 [MarshalAs(UnmanagedType.U4)] private readonly LaunchAction action; 27 [MarshalAs(UnmanagedType.U4)] private readonly LaunchAction action;
27 [MarshalAs(UnmanagedType.U4)] private readonly Display display; 28 [MarshalAs(UnmanagedType.U4)] private readonly Display display;
28 [MarshalAs(UnmanagedType.U4)] private readonly Restart restart; 29 [MarshalAs(UnmanagedType.U4)] private readonly Restart restart;
@@ -49,4 +50,25 @@ namespace WixToolset.Mba.Core
49 this.wzLayoutDirectory); 50 this.wzLayoutDirectory);
50 } 51 }
51 } 52 }
53
54 [Serializable]
55 [StructLayout(LayoutKind.Sequential)]
56 [GeneratedCodeAttribute("WixToolset.Bootstrapper.InteropCodeGenerator", "1.0.0.0")]
57 public struct BootstrapperCreateArgs
58 {
59 [MarshalAs(UnmanagedType.I4)] public readonly int cbSize;
60 [MarshalAs(UnmanagedType.I8)] public readonly long qwEngineAPIVersion;
61 public readonly IntPtr pfnBootstrapperEngineProc;
62 public readonly IntPtr pvBootstrapperEngineProcContext;
63 public readonly IntPtr pCommand;
64
65 public BootstrapperCreateArgs(long version, IntPtr pEngineProc, IntPtr pEngineContext, IntPtr pCommand)
66 {
67 this.cbSize = Marshal.SizeOf(typeof(BootstrapperCreateArgs));
68 this.qwEngineAPIVersion = version;
69 this.pfnBootstrapperEngineProc = pEngineProc;
70 this.pvBootstrapperEngineProcContext = pEngineContext;
71 this.pCommand = pCommand;
72 }
73 }
52} 74}