diff options
Diffstat (limited to 'src/WixToolset.Core/Compiler_UI.cs')
| -rw-r--r-- | src/WixToolset.Core/Compiler_UI.cs | 38 |
1 files changed, 33 insertions, 5 deletions
diff --git a/src/WixToolset.Core/Compiler_UI.cs b/src/WixToolset.Core/Compiler_UI.cs index 19c2fdcc..0b5b3980 100644 --- a/src/WixToolset.Core/Compiler_UI.cs +++ b/src/WixToolset.Core/Compiler_UI.cs | |||
| @@ -666,6 +666,7 @@ namespace WixToolset.Core | |||
| 666 | { | 666 | { |
| 667 | var sourceLineNumbers = Preprocessor.GetSourceLineNumbers(node); | 667 | var sourceLineNumbers = Preprocessor.GetSourceLineNumbers(node); |
| 668 | string action = null; | 668 | string action = null; |
| 669 | string message = null; | ||
| 669 | string template = null; | 670 | string template = null; |
| 670 | 671 | ||
| 671 | foreach (var attrib in node.Attributes()) | 672 | foreach (var attrib in node.Attributes()) |
| @@ -677,6 +678,9 @@ namespace WixToolset.Core | |||
| 677 | case "Action": | 678 | case "Action": |
| 678 | action = this.Core.GetAttributeValue(sourceLineNumbers, attrib); | 679 | action = this.Core.GetAttributeValue(sourceLineNumbers, attrib); |
| 679 | break; | 680 | break; |
| 681 | case "Message": | ||
| 682 | message = this.Core.GetAttributeValue(sourceLineNumbers, attrib); | ||
| 683 | break; | ||
| 680 | case "Template": | 684 | case "Template": |
| 681 | template = this.Core.GetAttributeValue(sourceLineNumbers, attrib); | 685 | template = this.Core.GetAttributeValue(sourceLineNumbers, attrib); |
| 682 | break; | 686 | break; |
| @@ -696,6 +700,11 @@ namespace WixToolset.Core | |||
| 696 | this.Core.Write(ErrorMessages.ExpectedAttribute(sourceLineNumbers, node.Name.LocalName, "Action")); | 700 | this.Core.Write(ErrorMessages.ExpectedAttribute(sourceLineNumbers, node.Name.LocalName, "Action")); |
| 697 | } | 701 | } |
| 698 | 702 | ||
| 703 | if (null == message) | ||
| 704 | { | ||
| 705 | message = Common.GetInnerText(node); | ||
| 706 | } | ||
| 707 | |||
| 699 | this.Core.ParseForExtensionElements(node); | 708 | this.Core.ParseForExtensionElements(node); |
| 700 | 709 | ||
| 701 | if (!this.Core.EncounteredError) | 710 | if (!this.Core.EncounteredError) |
| @@ -703,7 +712,7 @@ namespace WixToolset.Core | |||
| 703 | this.Core.AddTuple(new ActionTextTuple(sourceLineNumbers) | 712 | this.Core.AddTuple(new ActionTextTuple(sourceLineNumbers) |
| 704 | { | 713 | { |
| 705 | Action = action, | 714 | Action = action, |
| 706 | Description = Common.GetInnerText(node), | 715 | Description = message, |
| 707 | Template = template, | 716 | Template = template, |
| 708 | }); | 717 | }); |
| 709 | } | 718 | } |
| @@ -728,6 +737,9 @@ namespace WixToolset.Core | |||
| 728 | case "Id": | 737 | case "Id": |
| 729 | id = this.Core.GetAttributeIdentifier(sourceLineNumbers, attrib); | 738 | id = this.Core.GetAttributeIdentifier(sourceLineNumbers, attrib); |
| 730 | break; | 739 | break; |
| 740 | case "Value": | ||
| 741 | text = this.Core.GetAttributeValue(sourceLineNumbers, attrib); | ||
| 742 | break; | ||
| 731 | default: | 743 | default: |
| 732 | this.Core.UnexpectedAttribute(node, attrib); | 744 | this.Core.UnexpectedAttribute(node, attrib); |
| 733 | break; | 745 | break; |
| @@ -739,7 +751,10 @@ namespace WixToolset.Core | |||
| 739 | } | 751 | } |
| 740 | } | 752 | } |
| 741 | 753 | ||
| 742 | text = Common.GetInnerText(node); | 754 | if (null == text) |
| 755 | { | ||
| 756 | text = Common.GetInnerText(node); | ||
| 757 | } | ||
| 743 | 758 | ||
| 744 | if (null == id) | 759 | if (null == id) |
| 745 | { | 760 | { |
| @@ -1406,6 +1421,9 @@ namespace WixToolset.Core | |||
| 1406 | case "SourceFile": | 1421 | case "SourceFile": |
| 1407 | sourceFile = this.Core.GetAttributeValue(childSourceLineNumbers, attrib); | 1422 | sourceFile = this.Core.GetAttributeValue(childSourceLineNumbers, attrib); |
| 1408 | break; | 1423 | break; |
| 1424 | case "Value": | ||
| 1425 | text = this.Core.GetAttributeValue(childSourceLineNumbers, attrib); | ||
| 1426 | break; | ||
| 1409 | default: | 1427 | default: |
| 1410 | this.Core.UnexpectedAttribute(child, attrib); | 1428 | this.Core.UnexpectedAttribute(child, attrib); |
| 1411 | break; | 1429 | break; |
| @@ -1417,10 +1435,14 @@ namespace WixToolset.Core | |||
| 1417 | } | 1435 | } |
| 1418 | } | 1436 | } |
| 1419 | 1437 | ||
| 1420 | text = Common.GetInnerText(child); | 1438 | if (null == text) |
| 1439 | { | ||
| 1440 | text = Common.GetInnerText(child); | ||
| 1441 | } | ||
| 1442 | |||
| 1421 | if (!String.IsNullOrEmpty(text) && null != sourceFile) | 1443 | if (!String.IsNullOrEmpty(text) && null != sourceFile) |
| 1422 | { | 1444 | { |
| 1423 | this.Core.Write(ErrorMessages.IllegalAttributeWithInnerText(childSourceLineNumbers, child.Name.LocalName, "SourceFile")); | 1445 | this.Core.Write(ErrorMessages.IllegalAttributeWithOtherAttribute(childSourceLineNumbers, child.Name.LocalName, "SourceFile", "Text")); |
| 1424 | } | 1446 | } |
| 1425 | break; | 1447 | break; |
| 1426 | default: | 1448 | default: |
| @@ -1589,6 +1611,9 @@ namespace WixToolset.Core | |||
| 1589 | { | 1611 | { |
| 1590 | switch (attrib.Name.LocalName) | 1612 | switch (attrib.Name.LocalName) |
| 1591 | { | 1613 | { |
| 1614 | case "Condition": | ||
| 1615 | condition = this.Core.GetAttributeValue(sourceLineNumbers, attrib); | ||
| 1616 | break; | ||
| 1592 | case "Control": | 1617 | case "Control": |
| 1593 | if (null != control) | 1618 | if (null != control) |
| 1594 | { | 1619 | { |
| @@ -1627,7 +1652,10 @@ namespace WixToolset.Core | |||
| 1627 | } | 1652 | } |
| 1628 | } | 1653 | } |
| 1629 | 1654 | ||
| 1630 | condition = this.Core.GetConditionInnerText(node); | 1655 | if (null == condition) |
| 1656 | { | ||
| 1657 | condition = this.Core.GetConditionInnerText(node); | ||
| 1658 | } | ||
| 1631 | 1659 | ||
| 1632 | if (null == control) | 1660 | if (null == control) |
| 1633 | { | 1661 | { |
