Update errors/warnings now that well-known folders are optional
Rob Mensching committed
Feb 28, 2021 at 23:03 UTC
aa072ea259b9685804134debda936436b142e12f
2 files changed
+14
-9
src/WixToolset.Data/ErrorMessages.cs
-6
@@ -263,11 +263,6 @@ namespace WixToolset.Data
263
return Message(null, Ids.DirectoryPathRequired, "The parameter '{0}' must be followed by a directory path.", parameter);
264
}
265
266
- public static Message DirectoryRootWithoutName(SourceLineNumber sourceLineNumbers, string elementName, string attributeName)
267
- {
268
- return Message(sourceLineNumbers, Ids.DirectoryRootWithoutName, "The {0} element requires the {1} attribute because there is no parent {0} element.", elementName, attributeName);
269
- }
270
-
266
public static Message DisallowedMsiProperty(SourceLineNumber sourceLineNumbers, string property, string illegalValueList)
267
{
268
return Message(sourceLineNumbers, Ids.DisallowedMsiProperty, "The '{0}' MsiProperty is controlled by the bootstrapper and cannot be authored. (Illegal properties are: {1}.) Remove the MsiProperty element.", property, illegalValueList);
@@ -2320,7 +2315,6 @@ namespace WixToolset.Data
2315
CustomActionMultipleSources = 22,
2316
CustomActionMultipleTargets = 23,
2317
CustomActionIllegalInnerText = 24,
2323
- DirectoryRootWithoutName = 25,
2318
IllegalShortFilename = 26,
2319
IllegalLongFilename = 27,
2320
TableNameTooLong = 28,
src/WixToolset.Data/WarningMessages.cs
+14
-3
@@ -112,9 +112,14 @@ namespace WixToolset.Data
112
return Message(sourceLineNumbers, Ids.DeprecatedAttribute, "The {0}/@{1} attribute has been deprecated. Please use the {2} or {3} attribute instead.", elementName, attributeName, newAttributeName1, newAttributeName2);
113
}
114
115
+ public static Message DeprecatedAttributeValue(SourceLineNumber sourceLineNumbers, string attributeValue, string elementName, string attributeName)
116
+ {
117
+ return Message(sourceLineNumbers, Ids.DeprecatedAttributeValue, "The value \"{0}\" for the {1}/@{2} attribute has been deprecated. Remove the attribute.", attributeValue, elementName, attributeName);
118
+ }
119
+
120
public static Message DeprecatedAttributeValue(SourceLineNumber sourceLineNumbers, string attributeValue, string elementName, string attributeName, string newAttributeValue)
121
{
117
- return Message(sourceLineNumbers, Ids.DeprecatedAttributeValue, "The value \"{0}\" for the {1}/@{2} attribute has been deprecated. Please use \"{3}\" instead.", attributeValue, elementName, attributeName, newAttributeValue);
122
+ return Message(sourceLineNumbers, Ids.DeprecatedAttributeValue, "The value \"{0}\" for the {1}/@{2} attribute has been deprecated. Please use \"{3}\" instead.", attributeValue, elementName, attributeName, newAttributeValue);
123
}
124
125
public static Message DeprecatedCommandLineSwitch(string oldSwitch)
@@ -139,12 +144,12 @@ namespace WixToolset.Data
144
145
public static Message DeprecatedElement(SourceLineNumber sourceLineNumbers, string elementName, string newElementName)
146
{
142
- return Message(sourceLineNumbers, Ids.DeprecatedElement, "The {0} element has been deprecated. Please use the {1} element instead.", elementName, newElementName);
147
+ return Message(sourceLineNumbers, Ids.DeprecatedElement, "The {0} element has been deprecated. Please use the {1} element instead.", elementName, newElementName);
148
}
149
150
public static Message DeprecatedElement(SourceLineNumber sourceLineNumbers, string elementName, string newElementName1, string newElementName2)
151
{
147
- return Message(sourceLineNumbers, Ids.DeprecatedElement, "The {0} element has been deprecated. Please use the {1} or {2} element instead.", elementName, newElementName1, newElementName2);
152
+ return Message(sourceLineNumbers, Ids.DeprecatedElement, "The {0} element has been deprecated. Please use the {1} or {2} element instead.", elementName, newElementName1, newElementName2);
153
}
154
155
public static Message DeprecatedIgnoreModularizationElement(SourceLineNumber sourceLineNumbers)
@@ -582,6 +587,11 @@ namespace WixToolset.Data
587
return Message(null, Ids.TargetDirCorrectedDefaultDir, "The Directory with Id 'TARGETDIR' must have the value 'SourceDir' in its 'DefaultDir' column. This has been automatically corrected for you in the decompiled output.");
588
}
589
590
+ public static Message DefiningWellKnownDirectoryDeprecated(SourceLineNumber sourceLineNumbers, string directoryId)
591
+ {
592
+ return Message(null, Ids.DefiningWellKnownDirectoryDeprecated, "It is no longer necessary to define Directory with Id '{0}'. One will be provided automatically. Remove the Directory element.", directoryId);
593
+ }
594
+
595
public static Message TooManyProgIds(SourceLineNumber sourceLineNumbers, string clsId, string progId, string otherClsId)
596
{
597
return Message(sourceLineNumbers, Ids.TooManyProgIds, "Class '{0}' tried to use ProgId '{1}' which has already been associated with class '{2}'. This information will be left out of the decompiled output.", clsId, progId, otherClsId);
@@ -804,6 +814,7 @@ namespace WixToolset.Data
814
PathCanonicalized = 1152,
815
DetectConditionRecommended = 1153,
816
ExperimentalBundlePlatform = 1154,
817
+ DefiningWellKnownDirectoryDeprecated = 1155,
818
}
819
}
820
}