diff options
Diffstat (limited to 'src/WixToolset.Core/Compiler_Bundle.cs')
-rw-r--r-- | src/WixToolset.Core/Compiler_Bundle.cs | 46 |
1 files changed, 45 insertions, 1 deletions
diff --git a/src/WixToolset.Core/Compiler_Bundle.cs b/src/WixToolset.Core/Compiler_Bundle.cs index 7cdb8ca0..d73db84d 100644 --- a/src/WixToolset.Core/Compiler_Bundle.cs +++ b/src/WixToolset.Core/Compiler_Bundle.cs | |||
@@ -649,6 +649,7 @@ namespace WixToolset.Core | |||
649 | var sourceLineNumbers = Preprocessor.GetSourceLineNumbers(node); | 649 | var sourceLineNumbers = Preprocessor.GetSourceLineNumbers(node); |
650 | Identifier previousId = null; | 650 | Identifier previousId = null; |
651 | var previousType = ComplexReferenceChildType.Unknown; | 651 | var previousType = ComplexReferenceChildType.Unknown; |
652 | var dpiAwareness = WixBootstrapperApplicationDpiAwarenessType.PerMonitorV2; | ||
652 | 653 | ||
653 | // The BootstrapperApplication element acts like a Payload element so delegate to the "Payload" attribute parsing code to parse and create a Payload entry. | 654 | // The BootstrapperApplication element acts like a Payload element so delegate to the "Payload" attribute parsing code to parse and create a Payload entry. |
654 | var id = this.ParsePayloadElementContent(node, ComplexReferenceParentType.Container, Compiler.BurnUXContainerId, previousType, previousId, false); | 655 | var id = this.ParsePayloadElementContent(node, ComplexReferenceParentType.Container, Compiler.BurnUXContainerId, previousType, previousId, false); |
@@ -658,6 +659,40 @@ namespace WixToolset.Core | |||
658 | previousType = ComplexReferenceChildType.Payload; | 659 | previousType = ComplexReferenceChildType.Payload; |
659 | } | 660 | } |
660 | 661 | ||
662 | foreach (var attrib in node.Attributes()) | ||
663 | { | ||
664 | if (String.IsNullOrEmpty(attrib.Name.NamespaceName) || CompilerCore.WixNamespace == attrib.Name.Namespace) | ||
665 | { | ||
666 | switch (attrib.Name.LocalName) | ||
667 | { | ||
668 | case "DpiAwareness": | ||
669 | var dpiAwarenessValue = this.Core.GetAttributeValue(sourceLineNumbers, attrib); | ||
670 | switch (dpiAwarenessValue) | ||
671 | { | ||
672 | case "gdiScaled": | ||
673 | dpiAwareness = WixBootstrapperApplicationDpiAwarenessType.GdiScaled; | ||
674 | break; | ||
675 | case "perMonitor": | ||
676 | dpiAwareness = WixBootstrapperApplicationDpiAwarenessType.PerMonitor; | ||
677 | break; | ||
678 | case "perMonitorV2": | ||
679 | dpiAwareness = WixBootstrapperApplicationDpiAwarenessType.PerMonitorV2; | ||
680 | break; | ||
681 | case "system": | ||
682 | dpiAwareness = WixBootstrapperApplicationDpiAwarenessType.System; | ||
683 | break; | ||
684 | case "unaware": | ||
685 | dpiAwareness = WixBootstrapperApplicationDpiAwarenessType.Unaware; | ||
686 | break; | ||
687 | default: | ||
688 | this.Core.Write(ErrorMessages.IllegalAttributeValue(sourceLineNumbers, node.Name.LocalName, "DpiAwareness", dpiAwarenessValue, "gdiScaled", "perMonitor", "perMonitorV2", "system", "unaware")); | ||
689 | break; | ||
690 | } | ||
691 | break; | ||
692 | } | ||
693 | } | ||
694 | } | ||
695 | |||
661 | foreach (var child in node.Elements()) | 696 | foreach (var child in node.Elements()) |
662 | { | 697 | { |
663 | if (CompilerCore.WixNamespace == child.Name.Namespace) | 698 | if (CompilerCore.WixNamespace == child.Name.Namespace) |
@@ -702,7 +737,10 @@ namespace WixToolset.Core | |||
702 | 737 | ||
703 | if (null != id) | 738 | if (null != id) |
704 | { | 739 | { |
705 | this.Core.AddSymbol(new WixBootstrapperApplicationSymbol(sourceLineNumbers, id)); | 740 | this.Core.AddSymbol(new WixBootstrapperApplicationSymbol(sourceLineNumbers, id) |
741 | { | ||
742 | DpiAwareness = dpiAwareness, | ||
743 | }); | ||
706 | } | 744 | } |
707 | } | 745 | } |
708 | } | 746 | } |
@@ -1325,6 +1363,12 @@ namespace WixToolset.Core | |||
1325 | case "EnableSignatureVerification": | 1363 | case "EnableSignatureVerification": |
1326 | enableSignatureVerification = this.Core.GetAttributeYesNoValue(sourceLineNumbers, attrib); | 1364 | enableSignatureVerification = this.Core.GetAttributeYesNoValue(sourceLineNumbers, attrib); |
1327 | break; | 1365 | break; |
1366 | case "DpiAwareness": | ||
1367 | if (node.Name.LocalName != "BootstrapperApplication") | ||
1368 | { | ||
1369 | this.Core.UnexpectedAttribute(node, attrib); | ||
1370 | } | ||
1371 | break; | ||
1328 | default: | 1372 | default: |
1329 | this.Core.UnexpectedAttribute(node, attrib); | 1373 | this.Core.UnexpectedAttribute(node, attrib); |
1330 | break; | 1374 | break; |