diff options
| author | Rob Mensching <rob@firegiant.com> | 2019-05-08 14:13:31 -0700 |
|---|---|---|
| committer | Rob Mensching <rob@firegiant.com> | 2019-05-08 14:44:43 -0700 |
| commit | 75fd55d5a71c492c6ea904768858c51aa97da29f (patch) | |
| tree | 610047db1d5759a726ce88277bb2dfddcd01da45 /src/WixToolset.Core.WindowsInstaller/Decompile | |
| parent | d1dbe29f3856d012acf5f96e8e66c43b74ab490d (diff) | |
| download | wix-75fd55d5a71c492c6ea904768858c51aa97da29f.tar.gz wix-75fd55d5a71c492c6ea904768858c51aa97da29f.tar.bz2 wix-75fd55d5a71c492c6ea904768858c51aa97da29f.zip | |
Use new strongly typed tuples
Diffstat (limited to 'src/WixToolset.Core.WindowsInstaller/Decompile')
| -rw-r--r-- | src/WixToolset.Core.WindowsInstaller/Decompile/DecompileMsiOrMsmCommand.cs | 3 | ||||
| -rw-r--r-- | src/WixToolset.Core.WindowsInstaller/Decompile/Decompiler.cs | 402 |
2 files changed, 209 insertions, 196 deletions
diff --git a/src/WixToolset.Core.WindowsInstaller/Decompile/DecompileMsiOrMsmCommand.cs b/src/WixToolset.Core.WindowsInstaller/Decompile/DecompileMsiOrMsmCommand.cs index d44a863d..2ec39583 100644 --- a/src/WixToolset.Core.WindowsInstaller/Decompile/DecompileMsiOrMsmCommand.cs +++ b/src/WixToolset.Core.WindowsInstaller/Decompile/DecompileMsiOrMsmCommand.cs | |||
| @@ -6,12 +6,11 @@ namespace WixToolset.Core.WindowsInstaller.Unbind | |||
| 6 | using System.Collections.Generic; | 6 | using System.Collections.Generic; |
| 7 | using System.ComponentModel; | 7 | using System.ComponentModel; |
| 8 | using System.IO; | 8 | using System.IO; |
| 9 | using WixToolset.Core.Native; | 9 | using WixToolset.Core.WindowsInstaller.Msi; |
| 10 | using WixToolset.Data; | 10 | using WixToolset.Data; |
| 11 | using WixToolset.Extensibility; | 11 | using WixToolset.Extensibility; |
| 12 | using WixToolset.Extensibility.Data; | 12 | using WixToolset.Extensibility.Data; |
| 13 | using WixToolset.Extensibility.Services; | 13 | using WixToolset.Extensibility.Services; |
| 14 | using WixToolset.Msi; | ||
| 15 | 14 | ||
| 16 | internal class DecompileMsiOrMsmCommand | 15 | internal class DecompileMsiOrMsmCommand |
| 17 | { | 16 | { |
diff --git a/src/WixToolset.Core.WindowsInstaller/Decompile/Decompiler.cs b/src/WixToolset.Core.WindowsInstaller/Decompile/Decompiler.cs index 88393d6c..b6b6b8c3 100644 --- a/src/WixToolset.Core.WindowsInstaller/Decompile/Decompiler.cs +++ b/src/WixToolset.Core.WindowsInstaller/Decompile/Decompiler.cs | |||
| @@ -13,7 +13,6 @@ namespace WixToolset.Core.WindowsInstaller | |||
| 13 | using System.Text.RegularExpressions; | 13 | using System.Text.RegularExpressions; |
| 14 | using System.Xml.Linq; | 14 | using System.Xml.Linq; |
| 15 | using WixToolset.Core; | 15 | using WixToolset.Core; |
| 16 | using WixToolset.Core.Native; | ||
| 17 | using WixToolset.Core.WindowsInstaller.Rows; | 16 | using WixToolset.Core.WindowsInstaller.Rows; |
| 18 | using WixToolset.Data; | 17 | using WixToolset.Data; |
| 19 | using WixToolset.Data.Tuples; | 18 | using WixToolset.Data.Tuples; |
| @@ -30,6 +29,21 @@ namespace WixToolset.Core.WindowsInstaller | |||
| 30 | { | 29 | { |
| 31 | private static readonly Regex NullSplitter = new Regex(@"\[~]"); | 30 | private static readonly Regex NullSplitter = new Regex(@"\[~]"); |
| 32 | 31 | ||
| 32 | // NameToBit arrays | ||
| 33 | private static readonly string[] TextControlAttributes = { "Transparent", "NoPrefix", "NoWrap", "FormatSize", "UserLanguage" }; | ||
| 34 | private static readonly string[] HyperlinkControlAttributes = { "Transparent" }; | ||
| 35 | private static readonly string[] EditControlAttributes = { "Multiline", null, null, null, null, "Password" }; | ||
| 36 | private static readonly string[] ProgressControlAttributes = { "ProgressBlocks" }; | ||
| 37 | private static readonly string[] VolumeControlAttributes = { "Removable", "Fixed", "Remote", "CDROM", "RAMDisk", "Floppy", "ShowRollbackCost" }; | ||
| 38 | private static readonly string[] ListboxControlAttributes = { "Sorted", null, null, null, "UserLanguage" }; | ||
| 39 | private static readonly string[] ListviewControlAttributes = { "Sorted", null, null, null, "FixedSize", "Icon16", "Icon32" }; | ||
| 40 | private static readonly string[] ComboboxControlAttributes = { "Sorted", "ComboList", null, null, "UserLanguage" }; | ||
| 41 | private static readonly string[] RadioControlAttributes = { "Image", "PushLike", "Bitmap", "Icon", "FixedSize", "Icon16", "Icon32", null, "HasBorder" }; | ||
| 42 | private static readonly string[] ButtonControlAttributes = { "Image", null, "Bitmap", "Icon", "FixedSize", "Icon16", "Icon32", "ElevationShield" }; | ||
| 43 | private static readonly string[] IconControlAttributes = { "Image", null, null, null, "FixedSize", "Icon16", "Icon32" }; | ||
| 44 | private static readonly string[] BitmapControlAttributes = { "Image", null, null, null, "FixedSize" }; | ||
| 45 | private static readonly string[] CheckboxControlAttributes = { null, "PushLike", "Bitmap", "Icon", "FixedSize", "Icon16", "Icon32" }; | ||
| 46 | |||
| 33 | private bool compressed; | 47 | private bool compressed; |
| 34 | private bool shortNames; | 48 | private bool shortNames; |
| 35 | private DecompilerCore core; | 49 | private DecompilerCore core; |
| @@ -205,42 +219,42 @@ namespace WixToolset.Core.WindowsInstaller | |||
| 205 | /// <param name="control">The control element.</param> | 219 | /// <param name="control">The control element.</param> |
| 206 | private static void SetControlAttributes(int attributes, Wix.Control control) | 220 | private static void SetControlAttributes(int attributes, Wix.Control control) |
| 207 | { | 221 | { |
| 208 | if (0 == (attributes & MsiInterop.MsidbControlAttributesEnabled)) | 222 | if (0 == (attributes & WindowsInstallerConstants.MsidbControlAttributesEnabled)) |
| 209 | { | 223 | { |
| 210 | control.Disabled = Wix.YesNoType.yes; | 224 | control.Disabled = Wix.YesNoType.yes; |
| 211 | } | 225 | } |
| 212 | 226 | ||
| 213 | if (MsiInterop.MsidbControlAttributesIndirect == (attributes & MsiInterop.MsidbControlAttributesIndirect)) | 227 | if (WindowsInstallerConstants.MsidbControlAttributesIndirect == (attributes & WindowsInstallerConstants.MsidbControlAttributesIndirect)) |
| 214 | { | 228 | { |
| 215 | control.Indirect = Wix.YesNoType.yes; | 229 | control.Indirect = Wix.YesNoType.yes; |
| 216 | } | 230 | } |
| 217 | 231 | ||
| 218 | if (MsiInterop.MsidbControlAttributesInteger == (attributes & MsiInterop.MsidbControlAttributesInteger)) | 232 | if (WindowsInstallerConstants.MsidbControlAttributesInteger == (attributes & WindowsInstallerConstants.MsidbControlAttributesInteger)) |
| 219 | { | 233 | { |
| 220 | control.Integer = Wix.YesNoType.yes; | 234 | control.Integer = Wix.YesNoType.yes; |
| 221 | } | 235 | } |
| 222 | 236 | ||
| 223 | if (MsiInterop.MsidbControlAttributesLeftScroll == (attributes & MsiInterop.MsidbControlAttributesLeftScroll)) | 237 | if (WindowsInstallerConstants.MsidbControlAttributesLeftScroll == (attributes & WindowsInstallerConstants.MsidbControlAttributesLeftScroll)) |
| 224 | { | 238 | { |
| 225 | control.LeftScroll = Wix.YesNoType.yes; | 239 | control.LeftScroll = Wix.YesNoType.yes; |
| 226 | } | 240 | } |
| 227 | 241 | ||
| 228 | if (MsiInterop.MsidbControlAttributesRightAligned == (attributes & MsiInterop.MsidbControlAttributesRightAligned)) | 242 | if (WindowsInstallerConstants.MsidbControlAttributesRightAligned == (attributes & WindowsInstallerConstants.MsidbControlAttributesRightAligned)) |
| 229 | { | 243 | { |
| 230 | control.RightAligned = Wix.YesNoType.yes; | 244 | control.RightAligned = Wix.YesNoType.yes; |
| 231 | } | 245 | } |
| 232 | 246 | ||
| 233 | if (MsiInterop.MsidbControlAttributesRTLRO == (attributes & MsiInterop.MsidbControlAttributesRTLRO)) | 247 | if (WindowsInstallerConstants.MsidbControlAttributesRTLRO == (attributes & WindowsInstallerConstants.MsidbControlAttributesRTLRO)) |
| 234 | { | 248 | { |
| 235 | control.RightToLeft = Wix.YesNoType.yes; | 249 | control.RightToLeft = Wix.YesNoType.yes; |
| 236 | } | 250 | } |
| 237 | 251 | ||
| 238 | if (MsiInterop.MsidbControlAttributesSunken == (attributes & MsiInterop.MsidbControlAttributesSunken)) | 252 | if (WindowsInstallerConstants.MsidbControlAttributesSunken == (attributes & WindowsInstallerConstants.MsidbControlAttributesSunken)) |
| 239 | { | 253 | { |
| 240 | control.Sunken = Wix.YesNoType.yes; | 254 | control.Sunken = Wix.YesNoType.yes; |
| 241 | } | 255 | } |
| 242 | 256 | ||
| 243 | if (0 == (attributes & MsiInterop.MsidbControlAttributesVisible)) | 257 | if (0 == (attributes & WindowsInstallerConstants.MsidbControlAttributesVisible)) |
| 244 | { | 258 | { |
| 245 | control.Hidden = Wix.YesNoType.yes; | 259 | control.Hidden = Wix.YesNoType.yes; |
| 246 | } | 260 | } |
| @@ -873,7 +887,7 @@ namespace WixToolset.Core.WindowsInstaller | |||
| 873 | 887 | ||
| 874 | component.KeyPath = Wix.YesNoType.yes; | 888 | component.KeyPath = Wix.YesNoType.yes; |
| 875 | } | 889 | } |
| 876 | else if (MsiInterop.MsidbComponentAttributesRegistryKeyPath == (attributes & MsiInterop.MsidbComponentAttributesRegistryKeyPath)) | 890 | else if (WindowsInstallerConstants.MsidbComponentAttributesRegistryKeyPath == (attributes & WindowsInstallerConstants.MsidbComponentAttributesRegistryKeyPath)) |
| 877 | { | 891 | { |
| 878 | object registryObject = this.core.GetIndexedElement("Registry", Convert.ToString(row[5])); | 892 | object registryObject = this.core.GetIndexedElement("Registry", Convert.ToString(row[5])); |
| 879 | 893 | ||
| @@ -895,7 +909,7 @@ namespace WixToolset.Core.WindowsInstaller | |||
| 895 | this.Messaging.Write(WarningMessages.ExpectedForeignRow(row.SourceLineNumbers, "Component", row.GetPrimaryKey(DecompilerConstants.PrimaryKeyDelimiter), "KeyPath", Convert.ToString(row[5]), "Registry")); | 909 | this.Messaging.Write(WarningMessages.ExpectedForeignRow(row.SourceLineNumbers, "Component", row.GetPrimaryKey(DecompilerConstants.PrimaryKeyDelimiter), "KeyPath", Convert.ToString(row[5]), "Registry")); |
| 896 | } | 910 | } |
| 897 | } | 911 | } |
| 898 | else if (MsiInterop.MsidbComponentAttributesODBCDataSource == (attributes & MsiInterop.MsidbComponentAttributesODBCDataSource)) | 912 | else if (WindowsInstallerConstants.MsidbComponentAttributesODBCDataSource == (attributes & WindowsInstallerConstants.MsidbComponentAttributesODBCDataSource)) |
| 899 | { | 913 | { |
| 900 | var odbcDataSource = (Wix.ODBCDataSource)this.core.GetIndexedElement("ODBCDataSource", Convert.ToString(row[5])); | 914 | var odbcDataSource = (Wix.ODBCDataSource)this.core.GetIndexedElement("ODBCDataSource", Convert.ToString(row[5])); |
| 901 | 915 | ||
| @@ -1765,8 +1779,8 @@ namespace WixToolset.Core.WindowsInstaller | |||
| 1765 | foreach (var row in customActionTable.Rows) | 1779 | foreach (var row in customActionTable.Rows) |
| 1766 | { | 1780 | { |
| 1767 | var bits = Convert.ToInt32(row[1]); | 1781 | var bits = Convert.ToInt32(row[1]); |
| 1768 | if (MsiInterop.MsidbCustomActionTypeHideTarget == (bits & MsiInterop.MsidbCustomActionTypeHideTarget) && | 1782 | if (WindowsInstallerConstants.MsidbCustomActionTypeHideTarget == (bits & WindowsInstallerConstants.MsidbCustomActionTypeHideTarget) && |
| 1769 | MsiInterop.MsidbCustomActionTypeInScript == (bits & MsiInterop.MsidbCustomActionTypeInScript)) | 1783 | WindowsInstallerConstants.MsidbCustomActionTypeInScript == (bits & WindowsInstallerConstants.MsidbCustomActionTypeInScript)) |
| 1770 | { | 1784 | { |
| 1771 | var property = (Wix.Property)this.core.GetIndexedElement("Property", Convert.ToString(row[0])); | 1785 | var property = (Wix.Property)this.core.GetIndexedElement("Property", Convert.ToString(row[0])); |
| 1772 | 1786 | ||
| @@ -2674,17 +2688,17 @@ namespace WixToolset.Core.WindowsInstaller | |||
| 2674 | var attr = upgradeRow.Attributes; | 2688 | var attr = upgradeRow.Attributes; |
| 2675 | var removeFeatures = upgradeRow.Remove; | 2689 | var removeFeatures = upgradeRow.Remove; |
| 2676 | 2690 | ||
| 2677 | if (MsiInterop.MsidbUpgradeAttributesVersionMaxInclusive == (attr & MsiInterop.MsidbUpgradeAttributesVersionMaxInclusive)) | 2691 | if (WindowsInstallerConstants.MsidbUpgradeAttributesVersionMaxInclusive == (attr & WindowsInstallerConstants.MsidbUpgradeAttributesVersionMaxInclusive)) |
| 2678 | { | 2692 | { |
| 2679 | majorUpgrade.AllowSameVersionUpgrades = Wix.YesNoType.yes; | 2693 | majorUpgrade.AllowSameVersionUpgrades = Wix.YesNoType.yes; |
| 2680 | } | 2694 | } |
| 2681 | 2695 | ||
| 2682 | if (MsiInterop.MsidbUpgradeAttributesMigrateFeatures != (attr & MsiInterop.MsidbUpgradeAttributesMigrateFeatures)) | 2696 | if (WindowsInstallerConstants.MsidbUpgradeAttributesMigrateFeatures != (attr & WindowsInstallerConstants.MsidbUpgradeAttributesMigrateFeatures)) |
| 2683 | { | 2697 | { |
| 2684 | majorUpgrade.MigrateFeatures = Wix.YesNoType.no; | 2698 | majorUpgrade.MigrateFeatures = Wix.YesNoType.no; |
| 2685 | } | 2699 | } |
| 2686 | 2700 | ||
| 2687 | if (MsiInterop.MsidbUpgradeAttributesIgnoreRemoveFailure == (attr & MsiInterop.MsidbUpgradeAttributesIgnoreRemoveFailure)) | 2701 | if (WindowsInstallerConstants.MsidbUpgradeAttributesIgnoreRemoveFailure == (attr & WindowsInstallerConstants.MsidbUpgradeAttributesIgnoreRemoveFailure)) |
| 2688 | { | 2702 | { |
| 2689 | majorUpgrade.IgnoreRemoveFailure = Wix.YesNoType.yes; | 2703 | majorUpgrade.IgnoreRemoveFailure = Wix.YesNoType.yes; |
| 2690 | } | 2704 | } |
| @@ -4064,52 +4078,52 @@ namespace WixToolset.Core.WindowsInstaller | |||
| 4064 | switch (control.Type) | 4078 | switch (control.Type) |
| 4065 | { | 4079 | { |
| 4066 | case "Bitmap": | 4080 | case "Bitmap": |
| 4067 | specialAttributes = MsiInterop.BitmapControlAttributes; | 4081 | specialAttributes = BitmapControlAttributes; |
| 4068 | break; | 4082 | break; |
| 4069 | case "CheckBox": | 4083 | case "CheckBox": |
| 4070 | specialAttributes = MsiInterop.CheckboxControlAttributes; | 4084 | specialAttributes = CheckboxControlAttributes; |
| 4071 | break; | 4085 | break; |
| 4072 | case "ComboBox": | 4086 | case "ComboBox": |
| 4073 | specialAttributes = MsiInterop.ComboboxControlAttributes; | 4087 | specialAttributes = ComboboxControlAttributes; |
| 4074 | break; | 4088 | break; |
| 4075 | case "DirectoryCombo": | 4089 | case "DirectoryCombo": |
| 4076 | specialAttributes = MsiInterop.VolumeControlAttributes; | 4090 | specialAttributes = VolumeControlAttributes; |
| 4077 | break; | 4091 | break; |
| 4078 | case "Edit": | 4092 | case "Edit": |
| 4079 | specialAttributes = MsiInterop.EditControlAttributes; | 4093 | specialAttributes = EditControlAttributes; |
| 4080 | break; | 4094 | break; |
| 4081 | case "Icon": | 4095 | case "Icon": |
| 4082 | specialAttributes = MsiInterop.IconControlAttributes; | 4096 | specialAttributes = IconControlAttributes; |
| 4083 | break; | 4097 | break; |
| 4084 | case "ListBox": | 4098 | case "ListBox": |
| 4085 | specialAttributes = MsiInterop.ListboxControlAttributes; | 4099 | specialAttributes = ListboxControlAttributes; |
| 4086 | break; | 4100 | break; |
| 4087 | case "ListView": | 4101 | case "ListView": |
| 4088 | specialAttributes = MsiInterop.ListviewControlAttributes; | 4102 | specialAttributes = ListviewControlAttributes; |
| 4089 | break; | 4103 | break; |
| 4090 | case "MaskedEdit": | 4104 | case "MaskedEdit": |
| 4091 | specialAttributes = MsiInterop.EditControlAttributes; | 4105 | specialAttributes = EditControlAttributes; |
| 4092 | break; | 4106 | break; |
| 4093 | case "PathEdit": | 4107 | case "PathEdit": |
| 4094 | specialAttributes = MsiInterop.EditControlAttributes; | 4108 | specialAttributes = EditControlAttributes; |
| 4095 | break; | 4109 | break; |
| 4096 | case "ProgressBar": | 4110 | case "ProgressBar": |
| 4097 | specialAttributes = MsiInterop.ProgressControlAttributes; | 4111 | specialAttributes = ProgressControlAttributes; |
| 4098 | break; | 4112 | break; |
| 4099 | case "PushButton": | 4113 | case "PushButton": |
| 4100 | specialAttributes = MsiInterop.ButtonControlAttributes; | 4114 | specialAttributes = ButtonControlAttributes; |
| 4101 | break; | 4115 | break; |
| 4102 | case "RadioButtonGroup": | 4116 | case "RadioButtonGroup": |
| 4103 | specialAttributes = MsiInterop.RadioControlAttributes; | 4117 | specialAttributes = RadioControlAttributes; |
| 4104 | break; | 4118 | break; |
| 4105 | case "Text": | 4119 | case "Text": |
| 4106 | specialAttributes = MsiInterop.TextControlAttributes; | 4120 | specialAttributes = TextControlAttributes; |
| 4107 | break; | 4121 | break; |
| 4108 | case "VolumeCostList": | 4122 | case "VolumeCostList": |
| 4109 | specialAttributes = MsiInterop.VolumeControlAttributes; | 4123 | specialAttributes = VolumeControlAttributes; |
| 4110 | break; | 4124 | break; |
| 4111 | case "VolumeSelectCombo": | 4125 | case "VolumeSelectCombo": |
| 4112 | specialAttributes = MsiInterop.VolumeControlAttributes; | 4126 | specialAttributes = VolumeControlAttributes; |
| 4113 | break; | 4127 | break; |
| 4114 | default: | 4128 | default: |
| 4115 | specialAttributes = null; | 4129 | specialAttributes = null; |
| @@ -4644,52 +4658,52 @@ namespace WixToolset.Core.WindowsInstaller | |||
| 4644 | 4658 | ||
| 4645 | var type = Convert.ToInt32(row[1]); | 4659 | var type = Convert.ToInt32(row[1]); |
| 4646 | 4660 | ||
| 4647 | if (MsiInterop.MsidbCustomActionTypeHideTarget == (type & MsiInterop.MsidbCustomActionTypeHideTarget)) | 4661 | if (WindowsInstallerConstants.MsidbCustomActionTypeHideTarget == (type & WindowsInstallerConstants.MsidbCustomActionTypeHideTarget)) |
| 4648 | { | 4662 | { |
| 4649 | customAction.HideTarget = Wix.YesNoType.yes; | 4663 | customAction.HideTarget = Wix.YesNoType.yes; |
| 4650 | } | 4664 | } |
| 4651 | 4665 | ||
| 4652 | if (MsiInterop.MsidbCustomActionTypeNoImpersonate == (type & MsiInterop.MsidbCustomActionTypeNoImpersonate)) | 4666 | if (WindowsInstallerConstants.MsidbCustomActionTypeNoImpersonate == (type & WindowsInstallerConstants.MsidbCustomActionTypeNoImpersonate)) |
| 4653 | { | 4667 | { |
| 4654 | customAction.Impersonate = Wix.YesNoType.no; | 4668 | customAction.Impersonate = Wix.YesNoType.no; |
| 4655 | } | 4669 | } |
| 4656 | 4670 | ||
| 4657 | if (MsiInterop.MsidbCustomActionTypeTSAware == (type & MsiInterop.MsidbCustomActionTypeTSAware)) | 4671 | if (WindowsInstallerConstants.MsidbCustomActionTypeTSAware == (type & WindowsInstallerConstants.MsidbCustomActionTypeTSAware)) |
| 4658 | { | 4672 | { |
| 4659 | customAction.TerminalServerAware = Wix.YesNoType.yes; | 4673 | customAction.TerminalServerAware = Wix.YesNoType.yes; |
| 4660 | } | 4674 | } |
| 4661 | 4675 | ||
| 4662 | if (MsiInterop.MsidbCustomActionType64BitScript == (type & MsiInterop.MsidbCustomActionType64BitScript)) | 4676 | if (WindowsInstallerConstants.MsidbCustomActionType64BitScript == (type & WindowsInstallerConstants.MsidbCustomActionType64BitScript)) |
| 4663 | { | 4677 | { |
| 4664 | customAction.Win64 = Wix.YesNoType.yes; | 4678 | customAction.Win64 = Wix.YesNoType.yes; |
| 4665 | } | 4679 | } |
| 4666 | else if (MsiInterop.MsidbCustomActionTypeVBScript == (type & MsiInterop.MsidbCustomActionTypeVBScript) || | 4680 | else if (WindowsInstallerConstants.MsidbCustomActionTypeVBScript == (type & WindowsInstallerConstants.MsidbCustomActionTypeVBScript) || |
| 4667 | MsiInterop.MsidbCustomActionTypeJScript == (type & MsiInterop.MsidbCustomActionTypeJScript)) | 4681 | WindowsInstallerConstants.MsidbCustomActionTypeJScript == (type & WindowsInstallerConstants.MsidbCustomActionTypeJScript)) |
| 4668 | { | 4682 | { |
| 4669 | customAction.Win64 = Wix.YesNoType.no; | 4683 | customAction.Win64 = Wix.YesNoType.no; |
| 4670 | } | 4684 | } |
| 4671 | 4685 | ||
| 4672 | switch (type & MsiInterop.MsidbCustomActionTypeExecuteBits) | 4686 | switch (type & WindowsInstallerConstants.MsidbCustomActionTypeExecuteBits) |
| 4673 | { | 4687 | { |
| 4674 | case 0: | 4688 | case 0: |
| 4675 | // this is the default value | 4689 | // this is the default value |
| 4676 | break; | 4690 | break; |
| 4677 | case MsiInterop.MsidbCustomActionTypeFirstSequence: | 4691 | case WindowsInstallerConstants.MsidbCustomActionTypeFirstSequence: |
| 4678 | customAction.Execute = Wix.CustomAction.ExecuteType.firstSequence; | 4692 | customAction.Execute = Wix.CustomAction.ExecuteType.firstSequence; |
| 4679 | break; | 4693 | break; |
| 4680 | case MsiInterop.MsidbCustomActionTypeOncePerProcess: | 4694 | case WindowsInstallerConstants.MsidbCustomActionTypeOncePerProcess: |
| 4681 | customAction.Execute = Wix.CustomAction.ExecuteType.oncePerProcess; | 4695 | customAction.Execute = Wix.CustomAction.ExecuteType.oncePerProcess; |
| 4682 | break; | 4696 | break; |
| 4683 | case MsiInterop.MsidbCustomActionTypeClientRepeat: | 4697 | case WindowsInstallerConstants.MsidbCustomActionTypeClientRepeat: |
| 4684 | customAction.Execute = Wix.CustomAction.ExecuteType.secondSequence; | 4698 | customAction.Execute = Wix.CustomAction.ExecuteType.secondSequence; |
| 4685 | break; | 4699 | break; |
| 4686 | case MsiInterop.MsidbCustomActionTypeInScript: | 4700 | case WindowsInstallerConstants.MsidbCustomActionTypeInScript: |
| 4687 | customAction.Execute = Wix.CustomAction.ExecuteType.deferred; | 4701 | customAction.Execute = Wix.CustomAction.ExecuteType.deferred; |
| 4688 | break; | 4702 | break; |
| 4689 | case MsiInterop.MsidbCustomActionTypeInScript + MsiInterop.MsidbCustomActionTypeRollback: | 4703 | case WindowsInstallerConstants.MsidbCustomActionTypeInScript + WindowsInstallerConstants.MsidbCustomActionTypeRollback: |
| 4690 | customAction.Execute = Wix.CustomAction.ExecuteType.rollback; | 4704 | customAction.Execute = Wix.CustomAction.ExecuteType.rollback; |
| 4691 | break; | 4705 | break; |
| 4692 | case MsiInterop.MsidbCustomActionTypeInScript + MsiInterop.MsidbCustomActionTypeCommit: | 4706 | case WindowsInstallerConstants.MsidbCustomActionTypeInScript + WindowsInstallerConstants.MsidbCustomActionTypeCommit: |
| 4693 | customAction.Execute = Wix.CustomAction.ExecuteType.commit; | 4707 | customAction.Execute = Wix.CustomAction.ExecuteType.commit; |
| 4694 | break; | 4708 | break; |
| 4695 | default: | 4709 | default: |
| @@ -4697,18 +4711,18 @@ namespace WixToolset.Core.WindowsInstaller | |||
| 4697 | break; | 4711 | break; |
| 4698 | } | 4712 | } |
| 4699 | 4713 | ||
| 4700 | switch (type & MsiInterop.MsidbCustomActionTypeReturnBits) | 4714 | switch (type & WindowsInstallerConstants.MsidbCustomActionTypeReturnBits) |
| 4701 | { | 4715 | { |
| 4702 | case 0: | 4716 | case 0: |
| 4703 | // this is the default value | 4717 | // this is the default value |
| 4704 | break; | 4718 | break; |
| 4705 | case MsiInterop.MsidbCustomActionTypeContinue: | 4719 | case WindowsInstallerConstants.MsidbCustomActionTypeContinue: |
| 4706 | customAction.Return = Wix.CustomAction.ReturnType.ignore; | 4720 | customAction.Return = Wix.CustomAction.ReturnType.ignore; |
| 4707 | break; | 4721 | break; |
| 4708 | case MsiInterop.MsidbCustomActionTypeAsync: | 4722 | case WindowsInstallerConstants.MsidbCustomActionTypeAsync: |
| 4709 | customAction.Return = Wix.CustomAction.ReturnType.asyncWait; | 4723 | customAction.Return = Wix.CustomAction.ReturnType.asyncWait; |
| 4710 | break; | 4724 | break; |
| 4711 | case MsiInterop.MsidbCustomActionTypeAsync + MsiInterop.MsidbCustomActionTypeContinue: | 4725 | case WindowsInstallerConstants.MsidbCustomActionTypeAsync + WindowsInstallerConstants.MsidbCustomActionTypeContinue: |
| 4712 | customAction.Return = Wix.CustomAction.ReturnType.asyncNoWait; | 4726 | customAction.Return = Wix.CustomAction.ReturnType.asyncNoWait; |
| 4713 | break; | 4727 | break; |
| 4714 | default: | 4728 | default: |
| @@ -4716,25 +4730,25 @@ namespace WixToolset.Core.WindowsInstaller | |||
| 4716 | break; | 4730 | break; |
| 4717 | } | 4731 | } |
| 4718 | 4732 | ||
| 4719 | var source = type & MsiInterop.MsidbCustomActionTypeSourceBits; | 4733 | var source = type & WindowsInstallerConstants.MsidbCustomActionTypeSourceBits; |
| 4720 | switch (source) | 4734 | switch (source) |
| 4721 | { | 4735 | { |
| 4722 | case MsiInterop.MsidbCustomActionTypeBinaryData: | 4736 | case WindowsInstallerConstants.MsidbCustomActionTypeBinaryData: |
| 4723 | customAction.BinaryKey = Convert.ToString(row[2]); | 4737 | customAction.BinaryKey = Convert.ToString(row[2]); |
| 4724 | break; | 4738 | break; |
| 4725 | case MsiInterop.MsidbCustomActionTypeSourceFile: | 4739 | case WindowsInstallerConstants.MsidbCustomActionTypeSourceFile: |
| 4726 | if (null != row[2]) | 4740 | if (null != row[2]) |
| 4727 | { | 4741 | { |
| 4728 | customAction.FileKey = Convert.ToString(row[2]); | 4742 | customAction.FileKey = Convert.ToString(row[2]); |
| 4729 | } | 4743 | } |
| 4730 | break; | 4744 | break; |
| 4731 | case MsiInterop.MsidbCustomActionTypeDirectory: | 4745 | case WindowsInstallerConstants.MsidbCustomActionTypeDirectory: |
| 4732 | if (null != row[2]) | 4746 | if (null != row[2]) |
| 4733 | { | 4747 | { |
| 4734 | customAction.Directory = Convert.ToString(row[2]); | 4748 | customAction.Directory = Convert.ToString(row[2]); |
| 4735 | } | 4749 | } |
| 4736 | break; | 4750 | break; |
| 4737 | case MsiInterop.MsidbCustomActionTypeProperty: | 4751 | case WindowsInstallerConstants.MsidbCustomActionTypeProperty: |
| 4738 | customAction.Property = Convert.ToString(row[2]); | 4752 | customAction.Property = Convert.ToString(row[2]); |
| 4739 | break; | 4753 | break; |
| 4740 | default: | 4754 | default: |
| @@ -4742,16 +4756,16 @@ namespace WixToolset.Core.WindowsInstaller | |||
| 4742 | break; | 4756 | break; |
| 4743 | } | 4757 | } |
| 4744 | 4758 | ||
| 4745 | switch (type & MsiInterop.MsidbCustomActionTypeTargetBits) | 4759 | switch (type & WindowsInstallerConstants.MsidbCustomActionTypeTargetBits) |
| 4746 | { | 4760 | { |
| 4747 | case MsiInterop.MsidbCustomActionTypeDll: | 4761 | case WindowsInstallerConstants.MsidbCustomActionTypeDll: |
| 4748 | customAction.DllEntry = Convert.ToString(row[3]); | 4762 | customAction.DllEntry = Convert.ToString(row[3]); |
| 4749 | break; | 4763 | break; |
| 4750 | case MsiInterop.MsidbCustomActionTypeExe: | 4764 | case WindowsInstallerConstants.MsidbCustomActionTypeExe: |
| 4751 | customAction.ExeCommand = Convert.ToString(row[3]); | 4765 | customAction.ExeCommand = Convert.ToString(row[3]); |
| 4752 | break; | 4766 | break; |
| 4753 | case MsiInterop.MsidbCustomActionTypeTextData: | 4767 | case WindowsInstallerConstants.MsidbCustomActionTypeTextData: |
| 4754 | if (MsiInterop.MsidbCustomActionTypeSourceFile == source) | 4768 | if (WindowsInstallerConstants.MsidbCustomActionTypeSourceFile == source) |
| 4755 | { | 4769 | { |
| 4756 | customAction.Error = Convert.ToString(row[3]); | 4770 | customAction.Error = Convert.ToString(row[3]); |
| 4757 | } | 4771 | } |
| @@ -4760,8 +4774,8 @@ namespace WixToolset.Core.WindowsInstaller | |||
| 4760 | customAction.Value = Convert.ToString(row[3]); | 4774 | customAction.Value = Convert.ToString(row[3]); |
| 4761 | } | 4775 | } |
| 4762 | break; | 4776 | break; |
| 4763 | case MsiInterop.MsidbCustomActionTypeJScript: | 4777 | case WindowsInstallerConstants.MsidbCustomActionTypeJScript: |
| 4764 | if (MsiInterop.MsidbCustomActionTypeDirectory == source) | 4778 | if (WindowsInstallerConstants.MsidbCustomActionTypeDirectory == source) |
| 4765 | { | 4779 | { |
| 4766 | customAction.Script = Wix.CustomAction.ScriptType.jscript; | 4780 | customAction.Script = Wix.CustomAction.ScriptType.jscript; |
| 4767 | customAction.Content = Convert.ToString(row[3]); | 4781 | customAction.Content = Convert.ToString(row[3]); |
| @@ -4771,8 +4785,8 @@ namespace WixToolset.Core.WindowsInstaller | |||
| 4771 | customAction.JScriptCall = Convert.ToString(row[3]); | 4785 | customAction.JScriptCall = Convert.ToString(row[3]); |
| 4772 | } | 4786 | } |
| 4773 | break; | 4787 | break; |
| 4774 | case MsiInterop.MsidbCustomActionTypeVBScript: | 4788 | case WindowsInstallerConstants.MsidbCustomActionTypeVBScript: |
| 4775 | if (MsiInterop.MsidbCustomActionTypeDirectory == source) | 4789 | if (WindowsInstallerConstants.MsidbCustomActionTypeDirectory == source) |
| 4776 | { | 4790 | { |
| 4777 | customAction.Script = Wix.CustomAction.ScriptType.vbscript; | 4791 | customAction.Script = Wix.CustomAction.ScriptType.vbscript; |
| 4778 | customAction.Content = Convert.ToString(row[3]); | 4792 | customAction.Content = Convert.ToString(row[3]); |
| @@ -4782,7 +4796,7 @@ namespace WixToolset.Core.WindowsInstaller | |||
| 4782 | customAction.VBScriptCall = Convert.ToString(row[3]); | 4796 | customAction.VBScriptCall = Convert.ToString(row[3]); |
| 4783 | } | 4797 | } |
| 4784 | break; | 4798 | break; |
| 4785 | case MsiInterop.MsidbCustomActionTypeInstall: | 4799 | case WindowsInstallerConstants.MsidbCustomActionTypeInstall: |
| 4786 | this.Messaging.Write(WarningMessages.NestedInstall(row.SourceLineNumbers, table.Name, row.Fields[1].Column.Name, row[1])); | 4800 | this.Messaging.Write(WarningMessages.NestedInstall(row.SourceLineNumbers, table.Name, row.Fields[1].Column.Name, row[1])); |
| 4787 | continue; | 4801 | continue; |
| 4788 | default: | 4802 | default: |
| @@ -4791,7 +4805,7 @@ namespace WixToolset.Core.WindowsInstaller | |||
| 4791 | } | 4805 | } |
| 4792 | 4806 | ||
| 4793 | var extype = 4 < row.Fields.Length && null != row[4] ? Convert.ToInt32(row[4]) : 0; | 4807 | var extype = 4 < row.Fields.Length && null != row[4] ? Convert.ToInt32(row[4]) : 0; |
| 4794 | if (MsiInterop.MsidbCustomActionTypePatchUninstall == (extype & MsiInterop.MsidbCustomActionTypePatchUninstall)) | 4808 | if (WindowsInstallerConstants.MsidbCustomActionTypePatchUninstall == (extype & WindowsInstallerConstants.MsidbCustomActionTypePatchUninstall)) |
| 4795 | { | 4809 | { |
| 4796 | customAction.PatchUninstall = Wix.YesNoType.yes; | 4810 | customAction.PatchUninstall = Wix.YesNoType.yes; |
| 4797 | } | 4811 | } |
| @@ -4819,10 +4833,10 @@ namespace WixToolset.Core.WindowsInstaller | |||
| 4819 | { | 4833 | { |
| 4820 | switch (Convert.ToInt32(row[2])) | 4834 | switch (Convert.ToInt32(row[2])) |
| 4821 | { | 4835 | { |
| 4822 | case MsiInterop.MsidbLocatorTypeDirectory: | 4836 | case WindowsInstallerConstants.MsidbLocatorTypeDirectory: |
| 4823 | componentSearch.Type = Wix.ComponentSearch.TypeType.directory; | 4837 | componentSearch.Type = Wix.ComponentSearch.TypeType.directory; |
| 4824 | break; | 4838 | break; |
| 4825 | case MsiInterop.MsidbLocatorTypeFileName: | 4839 | case WindowsInstallerConstants.MsidbLocatorTypeFileName: |
| 4826 | // this is the default value | 4840 | // this is the default value |
| 4827 | break; | 4841 | break; |
| 4828 | default: | 4842 | default: |
| @@ -4875,36 +4889,36 @@ namespace WixToolset.Core.WindowsInstaller | |||
| 4875 | 4889 | ||
| 4876 | var attributes = Convert.ToInt32(row[3]); | 4890 | var attributes = Convert.ToInt32(row[3]); |
| 4877 | 4891 | ||
| 4878 | if (MsiInterop.MsidbComponentAttributesSourceOnly == (attributes & MsiInterop.MsidbComponentAttributesSourceOnly)) | 4892 | if (WindowsInstallerConstants.MsidbComponentAttributesSourceOnly == (attributes & WindowsInstallerConstants.MsidbComponentAttributesSourceOnly)) |
| 4879 | { | 4893 | { |
| 4880 | component.Location = Wix.Component.LocationType.source; | 4894 | component.Location = Wix.Component.LocationType.source; |
| 4881 | } | 4895 | } |
| 4882 | else if (MsiInterop.MsidbComponentAttributesOptional == (attributes & MsiInterop.MsidbComponentAttributesOptional)) | 4896 | else if (WindowsInstallerConstants.MsidbComponentAttributesOptional == (attributes & WindowsInstallerConstants.MsidbComponentAttributesOptional)) |
| 4883 | { | 4897 | { |
| 4884 | component.Location = Wix.Component.LocationType.either; | 4898 | component.Location = Wix.Component.LocationType.either; |
| 4885 | } | 4899 | } |
| 4886 | 4900 | ||
| 4887 | if (MsiInterop.MsidbComponentAttributesSharedDllRefCount == (attributes & MsiInterop.MsidbComponentAttributesSharedDllRefCount)) | 4901 | if (WindowsInstallerConstants.MsidbComponentAttributesSharedDllRefCount == (attributes & WindowsInstallerConstants.MsidbComponentAttributesSharedDllRefCount)) |
| 4888 | { | 4902 | { |
| 4889 | component.SharedDllRefCount = Wix.YesNoType.yes; | 4903 | component.SharedDllRefCount = Wix.YesNoType.yes; |
| 4890 | } | 4904 | } |
| 4891 | 4905 | ||
| 4892 | if (MsiInterop.MsidbComponentAttributesPermanent == (attributes & MsiInterop.MsidbComponentAttributesPermanent)) | 4906 | if (WindowsInstallerConstants.MsidbComponentAttributesPermanent == (attributes & WindowsInstallerConstants.MsidbComponentAttributesPermanent)) |
| 4893 | { | 4907 | { |
| 4894 | component.Permanent = Wix.YesNoType.yes; | 4908 | component.Permanent = Wix.YesNoType.yes; |
| 4895 | } | 4909 | } |
| 4896 | 4910 | ||
| 4897 | if (MsiInterop.MsidbComponentAttributesTransitive == (attributes & MsiInterop.MsidbComponentAttributesTransitive)) | 4911 | if (WindowsInstallerConstants.MsidbComponentAttributesTransitive == (attributes & WindowsInstallerConstants.MsidbComponentAttributesTransitive)) |
| 4898 | { | 4912 | { |
| 4899 | component.Transitive = Wix.YesNoType.yes; | 4913 | component.Transitive = Wix.YesNoType.yes; |
| 4900 | } | 4914 | } |
| 4901 | 4915 | ||
| 4902 | if (MsiInterop.MsidbComponentAttributesNeverOverwrite == (attributes & MsiInterop.MsidbComponentAttributesNeverOverwrite)) | 4916 | if (WindowsInstallerConstants.MsidbComponentAttributesNeverOverwrite == (attributes & WindowsInstallerConstants.MsidbComponentAttributesNeverOverwrite)) |
| 4903 | { | 4917 | { |
| 4904 | component.NeverOverwrite = Wix.YesNoType.yes; | 4918 | component.NeverOverwrite = Wix.YesNoType.yes; |
| 4905 | } | 4919 | } |
| 4906 | 4920 | ||
| 4907 | if (MsiInterop.MsidbComponentAttributes64bit == (attributes & MsiInterop.MsidbComponentAttributes64bit)) | 4921 | if (WindowsInstallerConstants.MsidbComponentAttributes64bit == (attributes & WindowsInstallerConstants.MsidbComponentAttributes64bit)) |
| 4908 | { | 4922 | { |
| 4909 | component.Win64 = Wix.YesNoType.yes; | 4923 | component.Win64 = Wix.YesNoType.yes; |
| 4910 | } | 4924 | } |
| @@ -4913,17 +4927,17 @@ namespace WixToolset.Core.WindowsInstaller | |||
| 4913 | component.Win64 = Wix.YesNoType.no; | 4927 | component.Win64 = Wix.YesNoType.no; |
| 4914 | } | 4928 | } |
| 4915 | 4929 | ||
| 4916 | if (MsiInterop.MsidbComponentAttributesDisableRegistryReflection == (attributes & MsiInterop.MsidbComponentAttributesDisableRegistryReflection)) | 4930 | if (WindowsInstallerConstants.MsidbComponentAttributesDisableRegistryReflection == (attributes & WindowsInstallerConstants.MsidbComponentAttributesDisableRegistryReflection)) |
| 4917 | { | 4931 | { |
| 4918 | component.DisableRegistryReflection = Wix.YesNoType.yes; | 4932 | component.DisableRegistryReflection = Wix.YesNoType.yes; |
| 4919 | } | 4933 | } |
| 4920 | 4934 | ||
| 4921 | if (MsiInterop.MsidbComponentAttributesUninstallOnSupersedence == (attributes & MsiInterop.MsidbComponentAttributesUninstallOnSupersedence)) | 4935 | if (WindowsInstallerConstants.MsidbComponentAttributesUninstallOnSupersedence == (attributes & WindowsInstallerConstants.MsidbComponentAttributesUninstallOnSupersedence)) |
| 4922 | { | 4936 | { |
| 4923 | component.UninstallWhenSuperseded = Wix.YesNoType.yes; | 4937 | component.UninstallWhenSuperseded = Wix.YesNoType.yes; |
| 4924 | } | 4938 | } |
| 4925 | 4939 | ||
| 4926 | if (MsiInterop.MsidbComponentAttributesShared == (attributes & MsiInterop.MsidbComponentAttributesShared)) | 4940 | if (WindowsInstallerConstants.MsidbComponentAttributesShared == (attributes & WindowsInstallerConstants.MsidbComponentAttributesShared)) |
| 4927 | { | 4941 | { |
| 4928 | component.Shared = Wix.YesNoType.yes; | 4942 | component.Shared = Wix.YesNoType.yes; |
| 4929 | } | 4943 | } |
| @@ -5003,57 +5017,57 @@ namespace WixToolset.Core.WindowsInstaller | |||
| 5003 | { | 5017 | { |
| 5004 | var attributes = Convert.ToInt32(row[5]); | 5018 | var attributes = Convert.ToInt32(row[5]); |
| 5005 | 5019 | ||
| 5006 | if (0 == (attributes & MsiInterop.MsidbDialogAttributesVisible)) | 5020 | if (0 == (attributes & WindowsInstallerConstants.MsidbDialogAttributesVisible)) |
| 5007 | { | 5021 | { |
| 5008 | dialog.Hidden = Wix.YesNoType.yes; | 5022 | dialog.Hidden = Wix.YesNoType.yes; |
| 5009 | } | 5023 | } |
| 5010 | 5024 | ||
| 5011 | if (0 == (attributes & MsiInterop.MsidbDialogAttributesModal)) | 5025 | if (0 == (attributes & WindowsInstallerConstants.MsidbDialogAttributesModal)) |
| 5012 | { | 5026 | { |
| 5013 | dialog.Modeless = Wix.YesNoType.yes; | 5027 | dialog.Modeless = Wix.YesNoType.yes; |
| 5014 | } | 5028 | } |
| 5015 | 5029 | ||
| 5016 | if (0 == (attributes & MsiInterop.MsidbDialogAttributesMinimize)) | 5030 | if (0 == (attributes & WindowsInstallerConstants.MsidbDialogAttributesMinimize)) |
| 5017 | { | 5031 | { |
| 5018 | dialog.NoMinimize = Wix.YesNoType.yes; | 5032 | dialog.NoMinimize = Wix.YesNoType.yes; |
| 5019 | } | 5033 | } |
| 5020 | 5034 | ||
| 5021 | if (MsiInterop.MsidbDialogAttributesSysModal == (attributes & MsiInterop.MsidbDialogAttributesSysModal)) | 5035 | if (WindowsInstallerConstants.MsidbDialogAttributesSysModal == (attributes & WindowsInstallerConstants.MsidbDialogAttributesSysModal)) |
| 5022 | { | 5036 | { |
| 5023 | dialog.SystemModal = Wix.YesNoType.yes; | 5037 | dialog.SystemModal = Wix.YesNoType.yes; |
| 5024 | } | 5038 | } |
| 5025 | 5039 | ||
| 5026 | if (MsiInterop.MsidbDialogAttributesKeepModeless == (attributes & MsiInterop.MsidbDialogAttributesKeepModeless)) | 5040 | if (WindowsInstallerConstants.MsidbDialogAttributesKeepModeless == (attributes & WindowsInstallerConstants.MsidbDialogAttributesKeepModeless)) |
| 5027 | { | 5041 | { |
| 5028 | dialog.KeepModeless = Wix.YesNoType.yes; | 5042 | dialog.KeepModeless = Wix.YesNoType.yes; |
| 5029 | } | 5043 | } |
| 5030 | 5044 | ||
| 5031 | if (MsiInterop.MsidbDialogAttributesTrackDiskSpace == (attributes & MsiInterop.MsidbDialogAttributesTrackDiskSpace)) | 5045 | if (WindowsInstallerConstants.MsidbDialogAttributesTrackDiskSpace == (attributes & WindowsInstallerConstants.MsidbDialogAttributesTrackDiskSpace)) |
| 5032 | { | 5046 | { |
| 5033 | dialog.TrackDiskSpace = Wix.YesNoType.yes; | 5047 | dialog.TrackDiskSpace = Wix.YesNoType.yes; |
| 5034 | } | 5048 | } |
| 5035 | 5049 | ||
| 5036 | if (MsiInterop.MsidbDialogAttributesUseCustomPalette == (attributes & MsiInterop.MsidbDialogAttributesUseCustomPalette)) | 5050 | if (WindowsInstallerConstants.MsidbDialogAttributesUseCustomPalette == (attributes & WindowsInstallerConstants.MsidbDialogAttributesUseCustomPalette)) |
| 5037 | { | 5051 | { |
| 5038 | dialog.CustomPalette = Wix.YesNoType.yes; | 5052 | dialog.CustomPalette = Wix.YesNoType.yes; |
| 5039 | } | 5053 | } |
| 5040 | 5054 | ||
| 5041 | if (MsiInterop.MsidbDialogAttributesRTLRO == (attributes & MsiInterop.MsidbDialogAttributesRTLRO)) | 5055 | if (WindowsInstallerConstants.MsidbDialogAttributesRTLRO == (attributes & WindowsInstallerConstants.MsidbDialogAttributesRTLRO)) |
| 5042 | { | 5056 | { |
| 5043 | dialog.RightToLeft = Wix.YesNoType.yes; | 5057 | dialog.RightToLeft = Wix.YesNoType.yes; |
| 5044 | } | 5058 | } |
| 5045 | 5059 | ||
| 5046 | if (MsiInterop.MsidbDialogAttributesRightAligned == (attributes & MsiInterop.MsidbDialogAttributesRightAligned)) | 5060 | if (WindowsInstallerConstants.MsidbDialogAttributesRightAligned == (attributes & WindowsInstallerConstants.MsidbDialogAttributesRightAligned)) |
| 5047 | { | 5061 | { |
| 5048 | dialog.RightAligned = Wix.YesNoType.yes; | 5062 | dialog.RightAligned = Wix.YesNoType.yes; |
| 5049 | } | 5063 | } |
| 5050 | 5064 | ||
| 5051 | if (MsiInterop.MsidbDialogAttributesLeftScroll == (attributes & MsiInterop.MsidbDialogAttributesLeftScroll)) | 5065 | if (WindowsInstallerConstants.MsidbDialogAttributesLeftScroll == (attributes & WindowsInstallerConstants.MsidbDialogAttributesLeftScroll)) |
| 5052 | { | 5066 | { |
| 5053 | dialog.LeftScroll = Wix.YesNoType.yes; | 5067 | dialog.LeftScroll = Wix.YesNoType.yes; |
| 5054 | } | 5068 | } |
| 5055 | 5069 | ||
| 5056 | if (MsiInterop.MsidbDialogAttributesError == (attributes & MsiInterop.MsidbDialogAttributesError)) | 5070 | if (WindowsInstallerConstants.MsidbDialogAttributesError == (attributes & WindowsInstallerConstants.MsidbDialogAttributesError)) |
| 5057 | { | 5071 | { |
| 5058 | dialog.ErrorDialog = Wix.YesNoType.yes; | 5072 | dialog.ErrorDialog = Wix.YesNoType.yes; |
| 5059 | } | 5073 | } |
| @@ -5558,40 +5572,40 @@ namespace WixToolset.Core.WindowsInstaller | |||
| 5558 | 5572 | ||
| 5559 | var attributes = Convert.ToInt32(row[7]); | 5573 | var attributes = Convert.ToInt32(row[7]); |
| 5560 | 5574 | ||
| 5561 | if (MsiInterop.MsidbFeatureAttributesFavorSource == (attributes & MsiInterop.MsidbFeatureAttributesFavorSource) && MsiInterop.MsidbFeatureAttributesFollowParent == (attributes & MsiInterop.MsidbFeatureAttributesFollowParent)) | 5575 | if (WindowsInstallerConstants.MsidbFeatureAttributesFavorSource == (attributes & WindowsInstallerConstants.MsidbFeatureAttributesFavorSource) && WindowsInstallerConstants.MsidbFeatureAttributesFollowParent == (attributes & WindowsInstallerConstants.MsidbFeatureAttributesFollowParent)) |
| 5562 | { | 5576 | { |
| 5563 | // TODO: display a warning for setting favor local and follow parent together | 5577 | // TODO: display a warning for setting favor local and follow parent together |
| 5564 | } | 5578 | } |
| 5565 | else if (MsiInterop.MsidbFeatureAttributesFavorSource == (attributes & MsiInterop.MsidbFeatureAttributesFavorSource)) | 5579 | else if (WindowsInstallerConstants.MsidbFeatureAttributesFavorSource == (attributes & WindowsInstallerConstants.MsidbFeatureAttributesFavorSource)) |
| 5566 | { | 5580 | { |
| 5567 | feature.InstallDefault = Wix.Feature.InstallDefaultType.source; | 5581 | feature.InstallDefault = Wix.Feature.InstallDefaultType.source; |
| 5568 | } | 5582 | } |
| 5569 | else if (MsiInterop.MsidbFeatureAttributesFollowParent == (attributes & MsiInterop.MsidbFeatureAttributesFollowParent)) | 5583 | else if (WindowsInstallerConstants.MsidbFeatureAttributesFollowParent == (attributes & WindowsInstallerConstants.MsidbFeatureAttributesFollowParent)) |
| 5570 | { | 5584 | { |
| 5571 | feature.InstallDefault = Wix.Feature.InstallDefaultType.followParent; | 5585 | feature.InstallDefault = Wix.Feature.InstallDefaultType.followParent; |
| 5572 | } | 5586 | } |
| 5573 | 5587 | ||
| 5574 | if (MsiInterop.MsidbFeatureAttributesFavorAdvertise == (attributes & MsiInterop.MsidbFeatureAttributesFavorAdvertise)) | 5588 | if (WindowsInstallerConstants.MsidbFeatureAttributesFavorAdvertise == (attributes & WindowsInstallerConstants.MsidbFeatureAttributesFavorAdvertise)) |
| 5575 | { | 5589 | { |
| 5576 | feature.TypicalDefault = Wix.Feature.TypicalDefaultType.advertise; | 5590 | feature.TypicalDefault = Wix.Feature.TypicalDefaultType.advertise; |
| 5577 | } | 5591 | } |
| 5578 | 5592 | ||
| 5579 | if (MsiInterop.MsidbFeatureAttributesDisallowAdvertise == (attributes & MsiInterop.MsidbFeatureAttributesDisallowAdvertise) && | 5593 | if (WindowsInstallerConstants.MsidbFeatureAttributesDisallowAdvertise == (attributes & WindowsInstallerConstants.MsidbFeatureAttributesDisallowAdvertise) && |
| 5580 | MsiInterop.MsidbFeatureAttributesNoUnsupportedAdvertise == (attributes & MsiInterop.MsidbFeatureAttributesNoUnsupportedAdvertise)) | 5594 | WindowsInstallerConstants.MsidbFeatureAttributesNoUnsupportedAdvertise == (attributes & WindowsInstallerConstants.MsidbFeatureAttributesNoUnsupportedAdvertise)) |
| 5581 | { | 5595 | { |
| 5582 | this.Messaging.Write(WarningMessages.InvalidAttributeCombination(row.SourceLineNumbers, "msidbFeatureAttributesDisallowAdvertise", "msidbFeatureAttributesNoUnsupportedAdvertise", "Feature.AllowAdvertiseType", "no")); | 5596 | this.Messaging.Write(WarningMessages.InvalidAttributeCombination(row.SourceLineNumbers, "msidbFeatureAttributesDisallowAdvertise", "msidbFeatureAttributesNoUnsupportedAdvertise", "Feature.AllowAdvertiseType", "no")); |
| 5583 | feature.AllowAdvertise = Wix.Feature.AllowAdvertiseType.no; | 5597 | feature.AllowAdvertise = Wix.Feature.AllowAdvertiseType.no; |
| 5584 | } | 5598 | } |
| 5585 | else if (MsiInterop.MsidbFeatureAttributesDisallowAdvertise == (attributes & MsiInterop.MsidbFeatureAttributesDisallowAdvertise)) | 5599 | else if (WindowsInstallerConstants.MsidbFeatureAttributesDisallowAdvertise == (attributes & WindowsInstallerConstants.MsidbFeatureAttributesDisallowAdvertise)) |
| 5586 | { | 5600 | { |
| 5587 | feature.AllowAdvertise = Wix.Feature.AllowAdvertiseType.no; | 5601 | feature.AllowAdvertise = Wix.Feature.AllowAdvertiseType.no; |
| 5588 | } | 5602 | } |
| 5589 | else if (MsiInterop.MsidbFeatureAttributesNoUnsupportedAdvertise == (attributes & MsiInterop.MsidbFeatureAttributesNoUnsupportedAdvertise)) | 5603 | else if (WindowsInstallerConstants.MsidbFeatureAttributesNoUnsupportedAdvertise == (attributes & WindowsInstallerConstants.MsidbFeatureAttributesNoUnsupportedAdvertise)) |
| 5590 | { | 5604 | { |
| 5591 | feature.AllowAdvertise = Wix.Feature.AllowAdvertiseType.system; | 5605 | feature.AllowAdvertise = Wix.Feature.AllowAdvertiseType.system; |
| 5592 | } | 5606 | } |
| 5593 | 5607 | ||
| 5594 | if (MsiInterop.MsidbFeatureAttributesUIDisallowAbsent == (attributes & MsiInterop.MsidbFeatureAttributesUIDisallowAbsent)) | 5608 | if (WindowsInstallerConstants.MsidbFeatureAttributesUIDisallowAbsent == (attributes & WindowsInstallerConstants.MsidbFeatureAttributesUIDisallowAbsent)) |
| 5595 | { | 5609 | { |
| 5596 | feature.Absent = Wix.Feature.AbsentType.disallow; | 5610 | feature.Absent = Wix.Feature.AbsentType.disallow; |
| 5597 | } | 5611 | } |
| @@ -5687,41 +5701,41 @@ namespace WixToolset.Core.WindowsInstaller | |||
| 5687 | } | 5701 | } |
| 5688 | } | 5702 | } |
| 5689 | 5703 | ||
| 5690 | if (MsiInterop.MsidbFileAttributesReadOnly == (fileRow.Attributes & MsiInterop.MsidbFileAttributesReadOnly)) | 5704 | if (WindowsInstallerConstants.MsidbFileAttributesReadOnly == (fileRow.Attributes & WindowsInstallerConstants.MsidbFileAttributesReadOnly)) |
| 5691 | { | 5705 | { |
| 5692 | file.ReadOnly = Wix.YesNoType.yes; | 5706 | file.ReadOnly = Wix.YesNoType.yes; |
| 5693 | } | 5707 | } |
| 5694 | 5708 | ||
| 5695 | if (MsiInterop.MsidbFileAttributesHidden == (fileRow.Attributes & MsiInterop.MsidbFileAttributesHidden)) | 5709 | if (WindowsInstallerConstants.MsidbFileAttributesHidden == (fileRow.Attributes & WindowsInstallerConstants.MsidbFileAttributesHidden)) |
| 5696 | { | 5710 | { |
| 5697 | file.Hidden = Wix.YesNoType.yes; | 5711 | file.Hidden = Wix.YesNoType.yes; |
| 5698 | } | 5712 | } |
| 5699 | 5713 | ||
| 5700 | if (MsiInterop.MsidbFileAttributesSystem == (fileRow.Attributes & MsiInterop.MsidbFileAttributesSystem)) | 5714 | if (WindowsInstallerConstants.MsidbFileAttributesSystem == (fileRow.Attributes & WindowsInstallerConstants.MsidbFileAttributesSystem)) |
| 5701 | { | 5715 | { |
| 5702 | file.System = Wix.YesNoType.yes; | 5716 | file.System = Wix.YesNoType.yes; |
| 5703 | } | 5717 | } |
| 5704 | 5718 | ||
| 5705 | if (MsiInterop.MsidbFileAttributesVital != (fileRow.Attributes & MsiInterop.MsidbFileAttributesVital)) | 5719 | if (WindowsInstallerConstants.MsidbFileAttributesVital != (fileRow.Attributes & WindowsInstallerConstants.MsidbFileAttributesVital)) |
| 5706 | { | 5720 | { |
| 5707 | file.Vital = Wix.YesNoType.no; | 5721 | file.Vital = Wix.YesNoType.no; |
| 5708 | } | 5722 | } |
| 5709 | 5723 | ||
| 5710 | if (MsiInterop.MsidbFileAttributesChecksum == (fileRow.Attributes & MsiInterop.MsidbFileAttributesChecksum)) | 5724 | if (WindowsInstallerConstants.MsidbFileAttributesChecksum == (fileRow.Attributes & WindowsInstallerConstants.MsidbFileAttributesChecksum)) |
| 5711 | { | 5725 | { |
| 5712 | file.Checksum = Wix.YesNoType.yes; | 5726 | file.Checksum = Wix.YesNoType.yes; |
| 5713 | } | 5727 | } |
| 5714 | 5728 | ||
| 5715 | if (MsiInterop.MsidbFileAttributesNoncompressed == (fileRow.Attributes & MsiInterop.MsidbFileAttributesNoncompressed) && | 5729 | if (WindowsInstallerConstants.MsidbFileAttributesNoncompressed == (fileRow.Attributes & WindowsInstallerConstants.MsidbFileAttributesNoncompressed) && |
| 5716 | MsiInterop.MsidbFileAttributesCompressed == (fileRow.Attributes & MsiInterop.MsidbFileAttributesCompressed)) | 5730 | WindowsInstallerConstants.MsidbFileAttributesCompressed == (fileRow.Attributes & WindowsInstallerConstants.MsidbFileAttributesCompressed)) |
| 5717 | { | 5731 | { |
| 5718 | // TODO: error | 5732 | // TODO: error |
| 5719 | } | 5733 | } |
| 5720 | else if (MsiInterop.MsidbFileAttributesNoncompressed == (fileRow.Attributes & MsiInterop.MsidbFileAttributesNoncompressed)) | 5734 | else if (WindowsInstallerConstants.MsidbFileAttributesNoncompressed == (fileRow.Attributes & WindowsInstallerConstants.MsidbFileAttributesNoncompressed)) |
| 5721 | { | 5735 | { |
| 5722 | file.Compressed = Wix.YesNoDefaultType.no; | 5736 | file.Compressed = Wix.YesNoDefaultType.no; |
| 5723 | } | 5737 | } |
| 5724 | else if (MsiInterop.MsidbFileAttributesCompressed == (fileRow.Attributes & MsiInterop.MsidbFileAttributesCompressed)) | 5738 | else if (WindowsInstallerConstants.MsidbFileAttributesCompressed == (fileRow.Attributes & WindowsInstallerConstants.MsidbFileAttributesCompressed)) |
| 5725 | { | 5739 | { |
| 5726 | file.Compressed = Wix.YesNoDefaultType.yes; | 5740 | file.Compressed = Wix.YesNoDefaultType.yes; |
| 5727 | } | 5741 | } |
| @@ -5886,13 +5900,13 @@ namespace WixToolset.Core.WindowsInstaller | |||
| 5886 | 5900 | ||
| 5887 | switch (Convert.ToInt32(row[6])) | 5901 | switch (Convert.ToInt32(row[6])) |
| 5888 | { | 5902 | { |
| 5889 | case MsiInterop.MsidbIniFileActionAddLine: | 5903 | case WindowsInstallerConstants.MsidbIniFileActionAddLine: |
| 5890 | iniFile.Action = Wix.IniFile.ActionType.addLine; | 5904 | iniFile.Action = Wix.IniFile.ActionType.addLine; |
| 5891 | break; | 5905 | break; |
| 5892 | case MsiInterop.MsidbIniFileActionCreateLine: | 5906 | case WindowsInstallerConstants.MsidbIniFileActionCreateLine: |
| 5893 | iniFile.Action = Wix.IniFile.ActionType.createLine; | 5907 | iniFile.Action = Wix.IniFile.ActionType.createLine; |
| 5894 | break; | 5908 | break; |
| 5895 | case MsiInterop.MsidbIniFileActionAddTag: | 5909 | case WindowsInstallerConstants.MsidbIniFileActionAddTag: |
| 5896 | iniFile.Action = Wix.IniFile.ActionType.addTag; | 5910 | iniFile.Action = Wix.IniFile.ActionType.addTag; |
| 5897 | break; | 5911 | break; |
| 5898 | default: | 5912 | default: |
| @@ -5953,13 +5967,13 @@ namespace WixToolset.Core.WindowsInstaller | |||
| 5953 | { | 5967 | { |
| 5954 | switch (Convert.ToInt32(row[5])) | 5968 | switch (Convert.ToInt32(row[5])) |
| 5955 | { | 5969 | { |
| 5956 | case MsiInterop.MsidbLocatorTypeDirectory: | 5970 | case WindowsInstallerConstants.MsidbLocatorTypeDirectory: |
| 5957 | iniFileSearch.Type = Wix.IniFileSearch.TypeType.directory; | 5971 | iniFileSearch.Type = Wix.IniFileSearch.TypeType.directory; |
| 5958 | break; | 5972 | break; |
| 5959 | case MsiInterop.MsidbLocatorTypeFileName: | 5973 | case WindowsInstallerConstants.MsidbLocatorTypeFileName: |
| 5960 | // this is the default value | 5974 | // this is the default value |
| 5961 | break; | 5975 | break; |
| 5962 | case MsiInterop.MsidbLocatorTypeRawValue: | 5976 | case WindowsInstallerConstants.MsidbLocatorTypeRawValue: |
| 5963 | iniFileSearch.Type = Wix.IniFileSearch.TypeType.raw; | 5977 | iniFileSearch.Type = Wix.IniFileSearch.TypeType.raw; |
| 5964 | break; | 5978 | break; |
| 5965 | default: | 5979 | default: |
| @@ -6371,12 +6385,12 @@ namespace WixToolset.Core.WindowsInstaller | |||
| 6371 | { | 6385 | { |
| 6372 | var attributes = Convert.ToInt32(row[5]); | 6386 | var attributes = Convert.ToInt32(row[5]); |
| 6373 | 6387 | ||
| 6374 | if (MsiInterop.MsidbMsmConfigurableOptionKeyNoOrphan == (attributes & MsiInterop.MsidbMsmConfigurableOptionKeyNoOrphan)) | 6388 | if (WindowsInstallerConstants.MsidbMsmConfigurableOptionKeyNoOrphan == (attributes & WindowsInstallerConstants.MsidbMsmConfigurableOptionKeyNoOrphan)) |
| 6375 | { | 6389 | { |
| 6376 | configuration.KeyNoOrphan = Wix.YesNoType.yes; | 6390 | configuration.KeyNoOrphan = Wix.YesNoType.yes; |
| 6377 | } | 6391 | } |
| 6378 | 6392 | ||
| 6379 | if (MsiInterop.MsidbMsmConfigurableOptionNonNullable == (attributes & MsiInterop.MsidbMsmConfigurableOptionNonNullable)) | 6393 | if (WindowsInstallerConstants.MsidbMsmConfigurableOptionNonNullable == (attributes & WindowsInstallerConstants.MsidbMsmConfigurableOptionNonNullable)) |
| 6380 | { | 6394 | { |
| 6381 | configuration.NonNullable = Wix.YesNoType.yes; | 6395 | configuration.NonNullable = Wix.YesNoType.yes; |
| 6382 | } | 6396 | } |
| @@ -6579,7 +6593,7 @@ namespace WixToolset.Core.WindowsInstaller | |||
| 6579 | { | 6593 | { |
| 6580 | case 0: | 6594 | case 0: |
| 6581 | break; | 6595 | break; |
| 6582 | case MsiInterop.MsidbMoveFileOptionsMove: | 6596 | case WindowsInstallerConstants.MsidbMoveFileOptionsMove: |
| 6583 | copyFile.Delete = Wix.YesNoType.yes; | 6597 | copyFile.Delete = Wix.YesNoType.yes; |
| 6584 | break; | 6598 | break; |
| 6585 | default: | 6599 | default: |
| @@ -6676,13 +6690,13 @@ namespace WixToolset.Core.WindowsInstaller | |||
| 6676 | 6690 | ||
| 6677 | switch (Convert.ToInt32(row[4])) | 6691 | switch (Convert.ToInt32(row[4])) |
| 6678 | { | 6692 | { |
| 6679 | case MsiInterop.MsidbCustomActionTypeExe + MsiInterop.MsidbCustomActionTypeBinaryData: | 6693 | case WindowsInstallerConstants.MsidbCustomActionTypeExe + WindowsInstallerConstants.MsidbCustomActionTypeBinaryData: |
| 6680 | embeddedChainer.BinarySource = Convert.ToString(row[3]); | 6694 | embeddedChainer.BinarySource = Convert.ToString(row[3]); |
| 6681 | break; | 6695 | break; |
| 6682 | case MsiInterop.MsidbCustomActionTypeExe + MsiInterop.MsidbCustomActionTypeSourceFile: | 6696 | case WindowsInstallerConstants.MsidbCustomActionTypeExe + WindowsInstallerConstants.MsidbCustomActionTypeSourceFile: |
| 6683 | embeddedChainer.FileSource = Convert.ToString(row[3]); | 6697 | embeddedChainer.FileSource = Convert.ToString(row[3]); |
| 6684 | break; | 6698 | break; |
| 6685 | case MsiInterop.MsidbCustomActionTypeExe + MsiInterop.MsidbCustomActionTypeProperty: | 6699 | case WindowsInstallerConstants.MsidbCustomActionTypeExe + WindowsInstallerConstants.MsidbCustomActionTypeProperty: |
| 6686 | embeddedChainer.PropertySource = Convert.ToString(row[3]); | 6700 | embeddedChainer.PropertySource = Convert.ToString(row[3]); |
| 6687 | break; | 6701 | break; |
| 6688 | default: | 6702 | default: |
| @@ -6708,7 +6722,7 @@ namespace WixToolset.Core.WindowsInstaller | |||
| 6708 | { | 6722 | { |
| 6709 | var attributes = Convert.ToInt32(row[2]); | 6723 | var attributes = Convert.ToInt32(row[2]); |
| 6710 | 6724 | ||
| 6711 | if (MsiInterop.MsidbEmbeddedUI == (attributes & MsiInterop.MsidbEmbeddedUI)) | 6725 | if (WindowsInstallerConstants.MsidbEmbeddedUI == (attributes & WindowsInstallerConstants.MsidbEmbeddedUI)) |
| 6712 | { | 6726 | { |
| 6713 | if (foundEmbeddedUI) | 6727 | if (foundEmbeddedUI) |
| 6714 | { | 6728 | { |
| @@ -6720,97 +6734,97 @@ namespace WixToolset.Core.WindowsInstaller | |||
| 6720 | embeddedUI.Name = Convert.ToString(row[1]); | 6734 | embeddedUI.Name = Convert.ToString(row[1]); |
| 6721 | 6735 | ||
| 6722 | var messageFilter = Convert.ToInt32(row[3]); | 6736 | var messageFilter = Convert.ToInt32(row[3]); |
| 6723 | if (0 == (messageFilter & MsiInterop.INSTALLLOGMODE_FATALEXIT)) | 6737 | if (0 == (messageFilter & WindowsInstallerConstants.INSTALLLOGMODE_FATALEXIT)) |
| 6724 | { | 6738 | { |
| 6725 | embeddedUI.IgnoreFatalExit = Wix.YesNoType.yes; | 6739 | embeddedUI.IgnoreFatalExit = Wix.YesNoType.yes; |
| 6726 | } | 6740 | } |
| 6727 | 6741 | ||
| 6728 | if (0 == (messageFilter & MsiInterop.INSTALLLOGMODE_ERROR)) | 6742 | if (0 == (messageFilter & WindowsInstallerConstants.INSTALLLOGMODE_ERROR)) |
| 6729 | { | 6743 | { |
| 6730 | embeddedUI.IgnoreError = Wix.YesNoType.yes; | 6744 | embeddedUI.IgnoreError = Wix.YesNoType.yes; |
| 6731 | } | 6745 | } |
| 6732 | 6746 | ||
| 6733 | if (0 == (messageFilter & MsiInterop.INSTALLLOGMODE_WARNING)) | 6747 | if (0 == (messageFilter & WindowsInstallerConstants.INSTALLLOGMODE_WARNING)) |
| 6734 | { | 6748 | { |
| 6735 | embeddedUI.IgnoreWarning = Wix.YesNoType.yes; | 6749 | embeddedUI.IgnoreWarning = Wix.YesNoType.yes; |
| 6736 | } | 6750 | } |
| 6737 | 6751 | ||
| 6738 | if (0 == (messageFilter & MsiInterop.INSTALLLOGMODE_USER)) | 6752 | if (0 == (messageFilter & WindowsInstallerConstants.INSTALLLOGMODE_USER)) |
| 6739 | { | 6753 | { |
| 6740 | embeddedUI.IgnoreUser = Wix.YesNoType.yes; | 6754 | embeddedUI.IgnoreUser = Wix.YesNoType.yes; |
| 6741 | } | 6755 | } |
| 6742 | 6756 | ||
| 6743 | if (0 == (messageFilter & MsiInterop.INSTALLLOGMODE_INFO)) | 6757 | if (0 == (messageFilter & WindowsInstallerConstants.INSTALLLOGMODE_INFO)) |
| 6744 | { | 6758 | { |
| 6745 | embeddedUI.IgnoreInfo = Wix.YesNoType.yes; | 6759 | embeddedUI.IgnoreInfo = Wix.YesNoType.yes; |
| 6746 | } | 6760 | } |
| 6747 | 6761 | ||
| 6748 | if (0 == (messageFilter & MsiInterop.INSTALLLOGMODE_FILESINUSE)) | 6762 | if (0 == (messageFilter & WindowsInstallerConstants.INSTALLLOGMODE_FILESINUSE)) |
| 6749 | { | 6763 | { |
| 6750 | embeddedUI.IgnoreFilesInUse = Wix.YesNoType.yes; | 6764 | embeddedUI.IgnoreFilesInUse = Wix.YesNoType.yes; |
| 6751 | } | 6765 | } |
| 6752 | 6766 | ||
| 6753 | if (0 == (messageFilter & MsiInterop.INSTALLLOGMODE_RESOLVESOURCE)) | 6767 | if (0 == (messageFilter & WindowsInstallerConstants.INSTALLLOGMODE_RESOLVESOURCE)) |
| 6754 | { | 6768 | { |
| 6755 | embeddedUI.IgnoreResolveSource = Wix.YesNoType.yes; | 6769 | embeddedUI.IgnoreResolveSource = Wix.YesNoType.yes; |
| 6756 | } | 6770 | } |
| 6757 | 6771 | ||
| 6758 | if (0 == (messageFilter & MsiInterop.INSTALLLOGMODE_OUTOFDISKSPACE)) | 6772 | if (0 == (messageFilter & WindowsInstallerConstants.INSTALLLOGMODE_OUTOFDISKSPACE)) |
| 6759 | { | 6773 | { |
| 6760 | embeddedUI.IgnoreOutOfDiskSpace = Wix.YesNoType.yes; | 6774 | embeddedUI.IgnoreOutOfDiskSpace = Wix.YesNoType.yes; |
| 6761 | } | 6775 | } |
| 6762 | 6776 | ||
| 6763 | if (0 == (messageFilter & MsiInterop.INSTALLLOGMODE_ACTIONSTART)) | 6777 | if (0 == (messageFilter & WindowsInstallerConstants.INSTALLLOGMODE_ACTIONSTART)) |
| 6764 | { | 6778 | { |
| 6765 | embeddedUI.IgnoreActionStart = Wix.YesNoType.yes; | 6779 | embeddedUI.IgnoreActionStart = Wix.YesNoType.yes; |
| 6766 | } | 6780 | } |
| 6767 | 6781 | ||
| 6768 | if (0 == (messageFilter & MsiInterop.INSTALLLOGMODE_ACTIONDATA)) | 6782 | if (0 == (messageFilter & WindowsInstallerConstants.INSTALLLOGMODE_ACTIONDATA)) |
| 6769 | { | 6783 | { |
| 6770 | embeddedUI.IgnoreActionData = Wix.YesNoType.yes; | 6784 | embeddedUI.IgnoreActionData = Wix.YesNoType.yes; |
| 6771 | } | 6785 | } |
| 6772 | 6786 | ||
| 6773 | if (0 == (messageFilter & MsiInterop.INSTALLLOGMODE_PROGRESS)) | 6787 | if (0 == (messageFilter & WindowsInstallerConstants.INSTALLLOGMODE_PROGRESS)) |
| 6774 | { | 6788 | { |
| 6775 | embeddedUI.IgnoreProgress = Wix.YesNoType.yes; | 6789 | embeddedUI.IgnoreProgress = Wix.YesNoType.yes; |
| 6776 | } | 6790 | } |
| 6777 | 6791 | ||
| 6778 | if (0 == (messageFilter & MsiInterop.INSTALLLOGMODE_COMMONDATA)) | 6792 | if (0 == (messageFilter & WindowsInstallerConstants.INSTALLLOGMODE_COMMONDATA)) |
| 6779 | { | 6793 | { |
| 6780 | embeddedUI.IgnoreCommonData = Wix.YesNoType.yes; | 6794 | embeddedUI.IgnoreCommonData = Wix.YesNoType.yes; |
| 6781 | } | 6795 | } |
| 6782 | 6796 | ||
| 6783 | if (0 == (messageFilter & MsiInterop.INSTALLLOGMODE_INITIALIZE)) | 6797 | if (0 == (messageFilter & WindowsInstallerConstants.INSTALLLOGMODE_INITIALIZE)) |
| 6784 | { | 6798 | { |
| 6785 | embeddedUI.IgnoreInitialize = Wix.YesNoType.yes; | 6799 | embeddedUI.IgnoreInitialize = Wix.YesNoType.yes; |
| 6786 | } | 6800 | } |
| 6787 | 6801 | ||
| 6788 | if (0 == (messageFilter & MsiInterop.INSTALLLOGMODE_TERMINATE)) | 6802 | if (0 == (messageFilter & WindowsInstallerConstants.INSTALLLOGMODE_TERMINATE)) |
| 6789 | { | 6803 | { |
| 6790 | embeddedUI.IgnoreTerminate = Wix.YesNoType.yes; | 6804 | embeddedUI.IgnoreTerminate = Wix.YesNoType.yes; |
| 6791 | } | 6805 | } |
| 6792 | 6806 | ||
| 6793 | if (0 == (messageFilter & MsiInterop.INSTALLLOGMODE_SHOWDIALOG)) | 6807 | if (0 == (messageFilter & WindowsInstallerConstants.INSTALLLOGMODE_SHOWDIALOG)) |
| 6794 | { | 6808 | { |
| 6795 | embeddedUI.IgnoreShowDialog = Wix.YesNoType.yes; | 6809 | embeddedUI.IgnoreShowDialog = Wix.YesNoType.yes; |
| 6796 | } | 6810 | } |
| 6797 | 6811 | ||
| 6798 | if (0 == (messageFilter & MsiInterop.INSTALLLOGMODE_RMFILESINUSE)) | 6812 | if (0 == (messageFilter & WindowsInstallerConstants.INSTALLLOGMODE_RMFILESINUSE)) |
| 6799 | { | 6813 | { |
| 6800 | embeddedUI.IgnoreRMFilesInUse = Wix.YesNoType.yes; | 6814 | embeddedUI.IgnoreRMFilesInUse = Wix.YesNoType.yes; |
| 6801 | } | 6815 | } |
| 6802 | 6816 | ||
| 6803 | if (0 == (messageFilter & MsiInterop.INSTALLLOGMODE_INSTALLSTART)) | 6817 | if (0 == (messageFilter & WindowsInstallerConstants.INSTALLLOGMODE_INSTALLSTART)) |
| 6804 | { | 6818 | { |
| 6805 | embeddedUI.IgnoreInstallStart = Wix.YesNoType.yes; | 6819 | embeddedUI.IgnoreInstallStart = Wix.YesNoType.yes; |
| 6806 | } | 6820 | } |
| 6807 | 6821 | ||
| 6808 | if (0 == (messageFilter & MsiInterop.INSTALLLOGMODE_INSTALLEND)) | 6822 | if (0 == (messageFilter & WindowsInstallerConstants.INSTALLLOGMODE_INSTALLEND)) |
| 6809 | { | 6823 | { |
| 6810 | embeddedUI.IgnoreInstallEnd = Wix.YesNoType.yes; | 6824 | embeddedUI.IgnoreInstallEnd = Wix.YesNoType.yes; |
| 6811 | } | 6825 | } |
| 6812 | 6826 | ||
| 6813 | if (MsiInterop.MsidbEmbeddedHandlesBasic == (attributes & MsiInterop.MsidbEmbeddedHandlesBasic)) | 6827 | if (WindowsInstallerConstants.MsidbEmbeddedHandlesBasic == (attributes & WindowsInstallerConstants.MsidbEmbeddedHandlesBasic)) |
| 6814 | { | 6828 | { |
| 6815 | embeddedUI.SupportBasicUI = Wix.YesNoType.yes; | 6829 | embeddedUI.SupportBasicUI = Wix.YesNoType.yes; |
| 6816 | } | 6830 | } |
| @@ -6997,10 +7011,10 @@ namespace WixToolset.Core.WindowsInstaller | |||
| 6997 | 7011 | ||
| 6998 | switch (Convert.ToInt32(row[4])) | 7012 | switch (Convert.ToInt32(row[4])) |
| 6999 | { | 7013 | { |
| 7000 | case MsiInterop.MsidbODBCDataSourceRegistrationPerMachine: | 7014 | case WindowsInstallerConstants.MsidbODBCDataSourceRegistrationPerMachine: |
| 7001 | odbcDataSource.Registration = Wix.ODBCDataSource.RegistrationType.machine; | 7015 | odbcDataSource.Registration = Wix.ODBCDataSource.RegistrationType.machine; |
| 7002 | break; | 7016 | break; |
| 7003 | case MsiInterop.MsidbODBCDataSourceRegistrationPerUser: | 7017 | case WindowsInstallerConstants.MsidbODBCDataSourceRegistrationPerUser: |
| 7004 | odbcDataSource.Registration = Wix.ODBCDataSource.RegistrationType.user; | 7018 | odbcDataSource.Registration = Wix.ODBCDataSource.RegistrationType.user; |
| 7005 | break; | 7019 | break; |
| 7006 | default: | 7020 | default: |
| @@ -7782,16 +7796,16 @@ namespace WixToolset.Core.WindowsInstaller | |||
| 7782 | 7796 | ||
| 7783 | switch (Convert.ToInt32(row[1])) | 7797 | switch (Convert.ToInt32(row[1])) |
| 7784 | { | 7798 | { |
| 7785 | case MsiInterop.MsidbRegistryRootClassesRoot: | 7799 | case WindowsInstallerConstants.MsidbRegistryRootClassesRoot: |
| 7786 | registrySearch.Root = Wix.RegistrySearch.RootType.HKCR; | 7800 | registrySearch.Root = Wix.RegistrySearch.RootType.HKCR; |
| 7787 | break; | 7801 | break; |
| 7788 | case MsiInterop.MsidbRegistryRootCurrentUser: | 7802 | case WindowsInstallerConstants.MsidbRegistryRootCurrentUser: |
| 7789 | registrySearch.Root = Wix.RegistrySearch.RootType.HKCU; | 7803 | registrySearch.Root = Wix.RegistrySearch.RootType.HKCU; |
| 7790 | break; | 7804 | break; |
| 7791 | case MsiInterop.MsidbRegistryRootLocalMachine: | 7805 | case WindowsInstallerConstants.MsidbRegistryRootLocalMachine: |
| 7792 | registrySearch.Root = Wix.RegistrySearch.RootType.HKLM; | 7806 | registrySearch.Root = Wix.RegistrySearch.RootType.HKLM; |
| 7793 | break; | 7807 | break; |
| 7794 | case MsiInterop.MsidbRegistryRootUsers: | 7808 | case WindowsInstallerConstants.MsidbRegistryRootUsers: |
| 7795 | registrySearch.Root = Wix.RegistrySearch.RootType.HKU; | 7809 | registrySearch.Root = Wix.RegistrySearch.RootType.HKU; |
| 7796 | break; | 7810 | break; |
| 7797 | default: | 7811 | default: |
| @@ -7814,10 +7828,10 @@ namespace WixToolset.Core.WindowsInstaller | |||
| 7814 | { | 7828 | { |
| 7815 | var type = Convert.ToInt32(row[4]); | 7829 | var type = Convert.ToInt32(row[4]); |
| 7816 | 7830 | ||
| 7817 | if (MsiInterop.MsidbLocatorType64bit == (type & MsiInterop.MsidbLocatorType64bit)) | 7831 | if (WindowsInstallerConstants.MsidbLocatorType64bit == (type & WindowsInstallerConstants.MsidbLocatorType64bit)) |
| 7818 | { | 7832 | { |
| 7819 | registrySearch.Win64 = Wix.YesNoType.yes; | 7833 | registrySearch.Win64 = Wix.YesNoType.yes; |
| 7820 | type &= ~MsiInterop.MsidbLocatorType64bit; | 7834 | type &= ~WindowsInstallerConstants.MsidbLocatorType64bit; |
| 7821 | } | 7835 | } |
| 7822 | else | 7836 | else |
| 7823 | { | 7837 | { |
| @@ -7826,13 +7840,13 @@ namespace WixToolset.Core.WindowsInstaller | |||
| 7826 | 7840 | ||
| 7827 | switch (type) | 7841 | switch (type) |
| 7828 | { | 7842 | { |
| 7829 | case MsiInterop.MsidbLocatorTypeDirectory: | 7843 | case WindowsInstallerConstants.MsidbLocatorTypeDirectory: |
| 7830 | registrySearch.Type = Wix.RegistrySearch.TypeType.directory; | 7844 | registrySearch.Type = Wix.RegistrySearch.TypeType.directory; |
| 7831 | break; | 7845 | break; |
| 7832 | case MsiInterop.MsidbLocatorTypeFileName: | 7846 | case WindowsInstallerConstants.MsidbLocatorTypeFileName: |
| 7833 | registrySearch.Type = Wix.RegistrySearch.TypeType.file; | 7847 | registrySearch.Type = Wix.RegistrySearch.TypeType.file; |
| 7834 | break; | 7848 | break; |
| 7835 | case MsiInterop.MsidbLocatorTypeRawValue: | 7849 | case WindowsInstallerConstants.MsidbLocatorTypeRawValue: |
| 7836 | registrySearch.Type = Wix.RegistrySearch.TypeType.raw; | 7850 | registrySearch.Type = Wix.RegistrySearch.TypeType.raw; |
| 7837 | break; | 7851 | break; |
| 7838 | default: | 7852 | default: |
| @@ -7863,13 +7877,13 @@ namespace WixToolset.Core.WindowsInstaller | |||
| 7863 | 7877 | ||
| 7864 | switch (Convert.ToInt32(row[4])) | 7878 | switch (Convert.ToInt32(row[4])) |
| 7865 | { | 7879 | { |
| 7866 | case MsiInterop.MsidbRemoveFileInstallModeOnInstall: | 7880 | case WindowsInstallerConstants.MsidbRemoveFileInstallModeOnInstall: |
| 7867 | removeFolder.On = Wix.InstallUninstallType.install; | 7881 | removeFolder.On = Wix.InstallUninstallType.install; |
| 7868 | break; | 7882 | break; |
| 7869 | case MsiInterop.MsidbRemoveFileInstallModeOnRemove: | 7883 | case WindowsInstallerConstants.MsidbRemoveFileInstallModeOnRemove: |
| 7870 | removeFolder.On = Wix.InstallUninstallType.uninstall; | 7884 | removeFolder.On = Wix.InstallUninstallType.uninstall; |
| 7871 | break; | 7885 | break; |
| 7872 | case MsiInterop.MsidbRemoveFileInstallModeOnBoth: | 7886 | case WindowsInstallerConstants.MsidbRemoveFileInstallModeOnBoth: |
| 7873 | removeFolder.On = Wix.InstallUninstallType.both; | 7887 | removeFolder.On = Wix.InstallUninstallType.both; |
| 7874 | break; | 7888 | break; |
| 7875 | default: | 7889 | default: |
| @@ -7909,13 +7923,13 @@ namespace WixToolset.Core.WindowsInstaller | |||
| 7909 | 7923 | ||
| 7910 | switch (Convert.ToInt32(row[4])) | 7924 | switch (Convert.ToInt32(row[4])) |
| 7911 | { | 7925 | { |
| 7912 | case MsiInterop.MsidbRemoveFileInstallModeOnInstall: | 7926 | case WindowsInstallerConstants.MsidbRemoveFileInstallModeOnInstall: |
| 7913 | removeFile.On = Wix.InstallUninstallType.install; | 7927 | removeFile.On = Wix.InstallUninstallType.install; |
| 7914 | break; | 7928 | break; |
| 7915 | case MsiInterop.MsidbRemoveFileInstallModeOnRemove: | 7929 | case WindowsInstallerConstants.MsidbRemoveFileInstallModeOnRemove: |
| 7916 | removeFile.On = Wix.InstallUninstallType.uninstall; | 7930 | removeFile.On = Wix.InstallUninstallType.uninstall; |
| 7917 | break; | 7931 | break; |
| 7918 | case MsiInterop.MsidbRemoveFileInstallModeOnBoth: | 7932 | case WindowsInstallerConstants.MsidbRemoveFileInstallModeOnBoth: |
| 7919 | removeFile.On = Wix.InstallUninstallType.both; | 7933 | removeFile.On = Wix.InstallUninstallType.both; |
| 7920 | break; | 7934 | break; |
| 7921 | default: | 7935 | default: |
| @@ -7976,10 +7990,10 @@ namespace WixToolset.Core.WindowsInstaller | |||
| 7976 | 7990 | ||
| 7977 | switch (Convert.ToInt32(row[6])) | 7991 | switch (Convert.ToInt32(row[6])) |
| 7978 | { | 7992 | { |
| 7979 | case MsiInterop.MsidbIniFileActionRemoveLine: | 7993 | case WindowsInstallerConstants.MsidbIniFileActionRemoveLine: |
| 7980 | iniFile.Action = Wix.IniFile.ActionType.removeLine; | 7994 | iniFile.Action = Wix.IniFile.ActionType.removeLine; |
| 7981 | break; | 7995 | break; |
| 7982 | case MsiInterop.MsidbIniFileActionRemoveTag: | 7996 | case WindowsInstallerConstants.MsidbIniFileActionRemoveTag: |
| 7983 | iniFile.Action = Wix.IniFile.ActionType.removeTag; | 7997 | iniFile.Action = Wix.IniFile.ActionType.removeTag; |
| 7984 | break; | 7998 | break; |
| 7985 | default: | 7999 | default: |
| @@ -8139,44 +8153,44 @@ namespace WixToolset.Core.WindowsInstaller | |||
| 8139 | serviceControl.Name = Convert.ToString(row[1]); | 8153 | serviceControl.Name = Convert.ToString(row[1]); |
| 8140 | 8154 | ||
| 8141 | var eventValue = Convert.ToInt32(row[2]); | 8155 | var eventValue = Convert.ToInt32(row[2]); |
| 8142 | if (MsiInterop.MsidbServiceControlEventStart == (eventValue & MsiInterop.MsidbServiceControlEventStart) && | 8156 | if (WindowsInstallerConstants.MsidbServiceControlEventStart == (eventValue & WindowsInstallerConstants.MsidbServiceControlEventStart) && |
| 8143 | MsiInterop.MsidbServiceControlEventUninstallStart == (eventValue & MsiInterop.MsidbServiceControlEventUninstallStart)) | 8157 | WindowsInstallerConstants.MsidbServiceControlEventUninstallStart == (eventValue & WindowsInstallerConstants.MsidbServiceControlEventUninstallStart)) |
| 8144 | { | 8158 | { |
| 8145 | serviceControl.Start = Wix.InstallUninstallType.both; | 8159 | serviceControl.Start = Wix.InstallUninstallType.both; |
| 8146 | } | 8160 | } |
| 8147 | else if (MsiInterop.MsidbServiceControlEventStart == (eventValue & MsiInterop.MsidbServiceControlEventStart)) | 8161 | else if (WindowsInstallerConstants.MsidbServiceControlEventStart == (eventValue & WindowsInstallerConstants.MsidbServiceControlEventStart)) |
| 8148 | { | 8162 | { |
| 8149 | serviceControl.Start = Wix.InstallUninstallType.install; | 8163 | serviceControl.Start = Wix.InstallUninstallType.install; |
| 8150 | } | 8164 | } |
| 8151 | else if (MsiInterop.MsidbServiceControlEventUninstallStart == (eventValue & MsiInterop.MsidbServiceControlEventUninstallStart)) | 8165 | else if (WindowsInstallerConstants.MsidbServiceControlEventUninstallStart == (eventValue & WindowsInstallerConstants.MsidbServiceControlEventUninstallStart)) |
| 8152 | { | 8166 | { |
| 8153 | serviceControl.Start = Wix.InstallUninstallType.uninstall; | 8167 | serviceControl.Start = Wix.InstallUninstallType.uninstall; |
| 8154 | } | 8168 | } |
| 8155 | 8169 | ||
| 8156 | if (MsiInterop.MsidbServiceControlEventStop == (eventValue & MsiInterop.MsidbServiceControlEventStop) && | 8170 | if (WindowsInstallerConstants.MsidbServiceControlEventStop == (eventValue & WindowsInstallerConstants.MsidbServiceControlEventStop) && |
| 8157 | MsiInterop.MsidbServiceControlEventUninstallStop == (eventValue & MsiInterop.MsidbServiceControlEventUninstallStop)) | 8171 | WindowsInstallerConstants.MsidbServiceControlEventUninstallStop == (eventValue & WindowsInstallerConstants.MsidbServiceControlEventUninstallStop)) |
| 8158 | { | 8172 | { |
| 8159 | serviceControl.Stop = Wix.InstallUninstallType.both; | 8173 | serviceControl.Stop = Wix.InstallUninstallType.both; |
| 8160 | } | 8174 | } |
| 8161 | else if (MsiInterop.MsidbServiceControlEventStop == (eventValue & MsiInterop.MsidbServiceControlEventStop)) | 8175 | else if (WindowsInstallerConstants.MsidbServiceControlEventStop == (eventValue & WindowsInstallerConstants.MsidbServiceControlEventStop)) |
| 8162 | { | 8176 | { |
| 8163 | serviceControl.Stop = Wix.InstallUninstallType.install; | 8177 | serviceControl.Stop = Wix.InstallUninstallType.install; |
| 8164 | } | 8178 | } |
| 8165 | else if (MsiInterop.MsidbServiceControlEventUninstallStop == (eventValue & MsiInterop.MsidbServiceControlEventUninstallStop)) | 8179 | else if (WindowsInstallerConstants.MsidbServiceControlEventUninstallStop == (eventValue & WindowsInstallerConstants.MsidbServiceControlEventUninstallStop)) |
| 8166 | { | 8180 | { |
| 8167 | serviceControl.Stop = Wix.InstallUninstallType.uninstall; | 8181 | serviceControl.Stop = Wix.InstallUninstallType.uninstall; |
| 8168 | } | 8182 | } |
| 8169 | 8183 | ||
| 8170 | if (MsiInterop.MsidbServiceControlEventDelete == (eventValue & MsiInterop.MsidbServiceControlEventDelete) && | 8184 | if (WindowsInstallerConstants.MsidbServiceControlEventDelete == (eventValue & WindowsInstallerConstants.MsidbServiceControlEventDelete) && |
| 8171 | MsiInterop.MsidbServiceControlEventUninstallDelete == (eventValue & MsiInterop.MsidbServiceControlEventUninstallDelete)) | 8185 | WindowsInstallerConstants.MsidbServiceControlEventUninstallDelete == (eventValue & WindowsInstallerConstants.MsidbServiceControlEventUninstallDelete)) |
| 8172 | { | 8186 | { |
| 8173 | serviceControl.Remove = Wix.InstallUninstallType.both; | 8187 | serviceControl.Remove = Wix.InstallUninstallType.both; |
| 8174 | } | 8188 | } |
| 8175 | else if (MsiInterop.MsidbServiceControlEventDelete == (eventValue & MsiInterop.MsidbServiceControlEventDelete)) | 8189 | else if (WindowsInstallerConstants.MsidbServiceControlEventDelete == (eventValue & WindowsInstallerConstants.MsidbServiceControlEventDelete)) |
| 8176 | { | 8190 | { |
| 8177 | serviceControl.Remove = Wix.InstallUninstallType.install; | 8191 | serviceControl.Remove = Wix.InstallUninstallType.install; |
| 8178 | } | 8192 | } |
| 8179 | else if (MsiInterop.MsidbServiceControlEventUninstallDelete == (eventValue & MsiInterop.MsidbServiceControlEventUninstallDelete)) | 8193 | else if (WindowsInstallerConstants.MsidbServiceControlEventUninstallDelete == (eventValue & WindowsInstallerConstants.MsidbServiceControlEventUninstallDelete)) |
| 8180 | { | 8194 | { |
| 8181 | serviceControl.Remove = Wix.InstallUninstallType.uninstall; | 8195 | serviceControl.Remove = Wix.InstallUninstallType.uninstall; |
| 8182 | } | 8196 | } |
| @@ -8239,35 +8253,35 @@ namespace WixToolset.Core.WindowsInstaller | |||
| 8239 | } | 8253 | } |
| 8240 | 8254 | ||
| 8241 | var serviceType = Convert.ToInt32(row[3]); | 8255 | var serviceType = Convert.ToInt32(row[3]); |
| 8242 | if (MsiInterop.MsidbServiceInstallInteractive == (serviceType & MsiInterop.MsidbServiceInstallInteractive)) | 8256 | if (WindowsInstallerConstants.MsidbServiceInstallInteractive == (serviceType & WindowsInstallerConstants.MsidbServiceInstallInteractive)) |
| 8243 | { | 8257 | { |
| 8244 | serviceInstall.Interactive = Wix.YesNoType.yes; | 8258 | serviceInstall.Interactive = Wix.YesNoType.yes; |
| 8245 | } | 8259 | } |
| 8246 | 8260 | ||
| 8247 | if (MsiInterop.MsidbServiceInstallOwnProcess == (serviceType & MsiInterop.MsidbServiceInstallOwnProcess) && | 8261 | if (WindowsInstallerConstants.MsidbServiceInstallOwnProcess == (serviceType & WindowsInstallerConstants.MsidbServiceInstallOwnProcess) && |
| 8248 | MsiInterop.MsidbServiceInstallShareProcess == (serviceType & MsiInterop.MsidbServiceInstallShareProcess)) | 8262 | WindowsInstallerConstants.MsidbServiceInstallShareProcess == (serviceType & WindowsInstallerConstants.MsidbServiceInstallShareProcess)) |
| 8249 | { | 8263 | { |
| 8250 | // TODO: warn | 8264 | // TODO: warn |
| 8251 | } | 8265 | } |
| 8252 | else if (MsiInterop.MsidbServiceInstallOwnProcess == (serviceType & MsiInterop.MsidbServiceInstallOwnProcess)) | 8266 | else if (WindowsInstallerConstants.MsidbServiceInstallOwnProcess == (serviceType & WindowsInstallerConstants.MsidbServiceInstallOwnProcess)) |
| 8253 | { | 8267 | { |
| 8254 | serviceInstall.Type = Wix.ServiceInstall.TypeType.ownProcess; | 8268 | serviceInstall.Type = Wix.ServiceInstall.TypeType.ownProcess; |
| 8255 | } | 8269 | } |
| 8256 | else if (MsiInterop.MsidbServiceInstallShareProcess == (serviceType & MsiInterop.MsidbServiceInstallShareProcess)) | 8270 | else if (WindowsInstallerConstants.MsidbServiceInstallShareProcess == (serviceType & WindowsInstallerConstants.MsidbServiceInstallShareProcess)) |
| 8257 | { | 8271 | { |
| 8258 | serviceInstall.Type = Wix.ServiceInstall.TypeType.shareProcess; | 8272 | serviceInstall.Type = Wix.ServiceInstall.TypeType.shareProcess; |
| 8259 | } | 8273 | } |
| 8260 | 8274 | ||
| 8261 | var startType = Convert.ToInt32(row[4]); | 8275 | var startType = Convert.ToInt32(row[4]); |
| 8262 | if (MsiInterop.MsidbServiceInstallDisabled == startType) | 8276 | if (WindowsInstallerConstants.MsidbServiceInstallDisabled == startType) |
| 8263 | { | 8277 | { |
| 8264 | serviceInstall.Start = Wix.ServiceInstall.StartType.disabled; | 8278 | serviceInstall.Start = Wix.ServiceInstall.StartType.disabled; |
| 8265 | } | 8279 | } |
| 8266 | else if (MsiInterop.MsidbServiceInstallDemandStart == startType) | 8280 | else if (WindowsInstallerConstants.MsidbServiceInstallDemandStart == startType) |
| 8267 | { | 8281 | { |
| 8268 | serviceInstall.Start = Wix.ServiceInstall.StartType.demand; | 8282 | serviceInstall.Start = Wix.ServiceInstall.StartType.demand; |
| 8269 | } | 8283 | } |
| 8270 | else if (MsiInterop.MsidbServiceInstallAutoStart == startType) | 8284 | else if (WindowsInstallerConstants.MsidbServiceInstallAutoStart == startType) |
| 8271 | { | 8285 | { |
| 8272 | serviceInstall.Start = Wix.ServiceInstall.StartType.auto; | 8286 | serviceInstall.Start = Wix.ServiceInstall.StartType.auto; |
| 8273 | } | 8287 | } |
| @@ -8277,11 +8291,11 @@ namespace WixToolset.Core.WindowsInstaller | |||
| 8277 | } | 8291 | } |
| 8278 | 8292 | ||
| 8279 | var errorControl = Convert.ToInt32(row[5]); | 8293 | var errorControl = Convert.ToInt32(row[5]); |
| 8280 | if (MsiInterop.MsidbServiceInstallErrorCritical == (errorControl & MsiInterop.MsidbServiceInstallErrorCritical)) | 8294 | if (WindowsInstallerConstants.MsidbServiceInstallErrorCritical == (errorControl & WindowsInstallerConstants.MsidbServiceInstallErrorCritical)) |
| 8281 | { | 8295 | { |
| 8282 | serviceInstall.ErrorControl = Wix.ServiceInstall.ErrorControlType.critical; | 8296 | serviceInstall.ErrorControl = Wix.ServiceInstall.ErrorControlType.critical; |
| 8283 | } | 8297 | } |
| 8284 | else if (MsiInterop.MsidbServiceInstallErrorNormal == (errorControl & MsiInterop.MsidbServiceInstallErrorNormal)) | 8298 | else if (WindowsInstallerConstants.MsidbServiceInstallErrorNormal == (errorControl & WindowsInstallerConstants.MsidbServiceInstallErrorNormal)) |
| 8285 | { | 8299 | { |
| 8286 | serviceInstall.ErrorControl = Wix.ServiceInstall.ErrorControlType.normal; | 8300 | serviceInstall.ErrorControl = Wix.ServiceInstall.ErrorControlType.normal; |
| 8287 | } | 8301 | } |
| @@ -8290,7 +8304,7 @@ namespace WixToolset.Core.WindowsInstaller | |||
| 8290 | serviceInstall.ErrorControl = Wix.ServiceInstall.ErrorControlType.ignore; | 8304 | serviceInstall.ErrorControl = Wix.ServiceInstall.ErrorControlType.ignore; |
| 8291 | } | 8305 | } |
| 8292 | 8306 | ||
| 8293 | if (MsiInterop.MsidbServiceInstallErrorControlVital == (errorControl & MsiInterop.MsidbServiceInstallErrorControlVital)) | 8307 | if (WindowsInstallerConstants.MsidbServiceInstallErrorControlVital == (errorControl & WindowsInstallerConstants.MsidbServiceInstallErrorControlVital)) |
| 8294 | { | 8308 | { |
| 8295 | serviceInstall.Vital = Wix.YesNoType.yes; | 8309 | serviceInstall.Vital = Wix.YesNoType.yes; |
| 8296 | } | 8310 | } |
| @@ -8768,22 +8782,22 @@ namespace WixToolset.Core.WindowsInstaller | |||
| 8768 | { | 8782 | { |
| 8769 | var styleBits = Convert.ToInt32(row[4]); | 8783 | var styleBits = Convert.ToInt32(row[4]); |
| 8770 | 8784 | ||
| 8771 | if (MsiInterop.MsidbTextStyleStyleBitsBold == (styleBits & MsiInterop.MsidbTextStyleStyleBitsBold)) | 8785 | if (WindowsInstallerConstants.MsidbTextStyleStyleBitsBold == (styleBits & WindowsInstallerConstants.MsidbTextStyleStyleBitsBold)) |
| 8772 | { | 8786 | { |
| 8773 | textStyle.Bold = Wix.YesNoType.yes; | 8787 | textStyle.Bold = Wix.YesNoType.yes; |
| 8774 | } | 8788 | } |
| 8775 | 8789 | ||
| 8776 | if (MsiInterop.MsidbTextStyleStyleBitsItalic == (styleBits & MsiInterop.MsidbTextStyleStyleBitsItalic)) | 8790 | if (WindowsInstallerConstants.MsidbTextStyleStyleBitsItalic == (styleBits & WindowsInstallerConstants.MsidbTextStyleStyleBitsItalic)) |
| 8777 | { | 8791 | { |
| 8778 | textStyle.Italic = Wix.YesNoType.yes; | 8792 | textStyle.Italic = Wix.YesNoType.yes; |
| 8779 | } | 8793 | } |
| 8780 | 8794 | ||
| 8781 | if (MsiInterop.MsidbTextStyleStyleBitsUnderline == (styleBits & MsiInterop.MsidbTextStyleStyleBitsUnderline)) | 8795 | if (WindowsInstallerConstants.MsidbTextStyleStyleBitsUnderline == (styleBits & WindowsInstallerConstants.MsidbTextStyleStyleBitsUnderline)) |
| 8782 | { | 8796 | { |
| 8783 | textStyle.Underline = Wix.YesNoType.yes; | 8797 | textStyle.Underline = Wix.YesNoType.yes; |
| 8784 | } | 8798 | } |
| 8785 | 8799 | ||
| 8786 | if (MsiInterop.MsidbTextStyleStyleBitsStrike == (styleBits & MsiInterop.MsidbTextStyleStyleBitsStrike)) | 8800 | if (WindowsInstallerConstants.MsidbTextStyleStyleBitsStrike == (styleBits & WindowsInstallerConstants.MsidbTextStyleStyleBitsStrike)) |
| 8787 | { | 8801 | { |
| 8788 | textStyle.Strike = Wix.YesNoType.yes; | 8802 | textStyle.Strike = Wix.YesNoType.yes; |
| 8789 | } | 8803 | } |
| @@ -8887,32 +8901,32 @@ namespace WixToolset.Core.WindowsInstaller | |||
| 8887 | upgradeVersion.Language = upgradeRow.Language; | 8901 | upgradeVersion.Language = upgradeRow.Language; |
| 8888 | } | 8902 | } |
| 8889 | 8903 | ||
| 8890 | if (MsiInterop.MsidbUpgradeAttributesMigrateFeatures == (upgradeRow.Attributes & MsiInterop.MsidbUpgradeAttributesMigrateFeatures)) | 8904 | if (WindowsInstallerConstants.MsidbUpgradeAttributesMigrateFeatures == (upgradeRow.Attributes & WindowsInstallerConstants.MsidbUpgradeAttributesMigrateFeatures)) |
| 8891 | { | 8905 | { |
| 8892 | upgradeVersion.MigrateFeatures = Wix.YesNoType.yes; | 8906 | upgradeVersion.MigrateFeatures = Wix.YesNoType.yes; |
| 8893 | } | 8907 | } |
| 8894 | 8908 | ||
| 8895 | if (MsiInterop.MsidbUpgradeAttributesOnlyDetect == (upgradeRow.Attributes & MsiInterop.MsidbUpgradeAttributesOnlyDetect)) | 8909 | if (WindowsInstallerConstants.MsidbUpgradeAttributesOnlyDetect == (upgradeRow.Attributes & WindowsInstallerConstants.MsidbUpgradeAttributesOnlyDetect)) |
| 8896 | { | 8910 | { |
| 8897 | upgradeVersion.OnlyDetect = Wix.YesNoType.yes; | 8911 | upgradeVersion.OnlyDetect = Wix.YesNoType.yes; |
| 8898 | } | 8912 | } |
| 8899 | 8913 | ||
| 8900 | if (MsiInterop.MsidbUpgradeAttributesIgnoreRemoveFailure == (upgradeRow.Attributes & MsiInterop.MsidbUpgradeAttributesIgnoreRemoveFailure)) | 8914 | if (WindowsInstallerConstants.MsidbUpgradeAttributesIgnoreRemoveFailure == (upgradeRow.Attributes & WindowsInstallerConstants.MsidbUpgradeAttributesIgnoreRemoveFailure)) |
| 8901 | { | 8915 | { |
| 8902 | upgradeVersion.IgnoreRemoveFailure = Wix.YesNoType.yes; | 8916 | upgradeVersion.IgnoreRemoveFailure = Wix.YesNoType.yes; |
| 8903 | } | 8917 | } |
| 8904 | 8918 | ||
| 8905 | if (MsiInterop.MsidbUpgradeAttributesVersionMinInclusive == (upgradeRow.Attributes & MsiInterop.MsidbUpgradeAttributesVersionMinInclusive)) | 8919 | if (WindowsInstallerConstants.MsidbUpgradeAttributesVersionMinInclusive == (upgradeRow.Attributes & WindowsInstallerConstants.MsidbUpgradeAttributesVersionMinInclusive)) |
| 8906 | { | 8920 | { |
| 8907 | upgradeVersion.IncludeMinimum = Wix.YesNoType.yes; | 8921 | upgradeVersion.IncludeMinimum = Wix.YesNoType.yes; |
| 8908 | } | 8922 | } |
| 8909 | 8923 | ||
| 8910 | if (MsiInterop.MsidbUpgradeAttributesVersionMaxInclusive == (upgradeRow.Attributes & MsiInterop.MsidbUpgradeAttributesVersionMaxInclusive)) | 8924 | if (WindowsInstallerConstants.MsidbUpgradeAttributesVersionMaxInclusive == (upgradeRow.Attributes & WindowsInstallerConstants.MsidbUpgradeAttributesVersionMaxInclusive)) |
| 8911 | { | 8925 | { |
| 8912 | upgradeVersion.IncludeMaximum = Wix.YesNoType.yes; | 8926 | upgradeVersion.IncludeMaximum = Wix.YesNoType.yes; |
| 8913 | } | 8927 | } |
| 8914 | 8928 | ||
| 8915 | if (MsiInterop.MsidbUpgradeAttributesLanguagesExclusive == (upgradeRow.Attributes & MsiInterop.MsidbUpgradeAttributesLanguagesExclusive)) | 8929 | if (WindowsInstallerConstants.MsidbUpgradeAttributesLanguagesExclusive == (upgradeRow.Attributes & WindowsInstallerConstants.MsidbUpgradeAttributesLanguagesExclusive)) |
| 8916 | { | 8930 | { |
| 8917 | upgradeVersion.ExcludeLanguages = Wix.YesNoType.yes; | 8931 | upgradeVersion.ExcludeLanguages = Wix.YesNoType.yes; |
| 8918 | } | 8932 | } |
| @@ -9121,16 +9135,16 @@ namespace WixToolset.Core.WindowsInstaller | |||
| 9121 | case (-1): | 9135 | case (-1): |
| 9122 | registryRootType = Wix.RegistryRootType.HKMU; | 9136 | registryRootType = Wix.RegistryRootType.HKMU; |
| 9123 | return true; | 9137 | return true; |
| 9124 | case MsiInterop.MsidbRegistryRootClassesRoot: | 9138 | case WindowsInstallerConstants.MsidbRegistryRootClassesRoot: |
| 9125 | registryRootType = Wix.RegistryRootType.HKCR; | 9139 | registryRootType = Wix.RegistryRootType.HKCR; |
| 9126 | return true; | 9140 | return true; |
| 9127 | case MsiInterop.MsidbRegistryRootCurrentUser: | 9141 | case WindowsInstallerConstants.MsidbRegistryRootCurrentUser: |
| 9128 | registryRootType = Wix.RegistryRootType.HKCU; | 9142 | registryRootType = Wix.RegistryRootType.HKCU; |
| 9129 | return true; | 9143 | return true; |
| 9130 | case MsiInterop.MsidbRegistryRootLocalMachine: | 9144 | case WindowsInstallerConstants.MsidbRegistryRootLocalMachine: |
| 9131 | registryRootType = Wix.RegistryRootType.HKLM; | 9145 | registryRootType = Wix.RegistryRootType.HKLM; |
| 9132 | return true; | 9146 | return true; |
| 9133 | case MsiInterop.MsidbRegistryRootUsers: | 9147 | case WindowsInstallerConstants.MsidbRegistryRootUsers: |
| 9134 | registryRootType = Wix.RegistryRootType.HKU; | 9148 | registryRootType = Wix.RegistryRootType.HKU; |
| 9135 | return true; | 9149 | return true; |
| 9136 | default: | 9150 | default: |
