Change the ReplaceSymbolChars list to an indexed list (like transitions)
This commit is contained in:
parent
4163b9d46f
commit
9bf88111f1
@ -1982,7 +1982,7 @@ namespace VEPROMS.CSLA.Library
|
||||
{
|
||||
get
|
||||
{
|
||||
return (_ReplaceSymbolCharList == null) ? _ReplaceSymbolCharList = new ReplaceSymbolCharList(SelectNodes("ReplaceSymbolChars/ReplaceChar")) : _ReplaceSymbolCharList;
|
||||
return (_ReplaceSymbolCharList == null) ? _ReplaceSymbolCharList = new ReplaceSymbolCharList(SelectNodes("ReplaceSymbolChars/ReplaceChar"),MyFormat) : _ReplaceSymbolCharList;
|
||||
}
|
||||
set { _ReplaceSymbolCharList = value; }
|
||||
}
|
||||
@ -3010,10 +3010,18 @@ namespace VEPROMS.CSLA.Library
|
||||
#endregion
|
||||
#region ReplaceChar
|
||||
[TypeConverter(typeof(ExpandableObjectConverter))]
|
||||
public class ReplaceChar : vlnFormatItem
|
||||
public class ReplaceChar : vlnFormatItem, IVlnIndexedFormatItem
|
||||
{
|
||||
public ReplaceChar(XmlNode xmlNode) : base(xmlNode) { }
|
||||
public ReplaceChar() : base() { }
|
||||
private LazyLoad<int?> _Index;
|
||||
public int? Index
|
||||
{
|
||||
get
|
||||
{
|
||||
return LazyLoad(ref _Index, "@Index");
|
||||
}
|
||||
}
|
||||
[Category("Strings")]
|
||||
private LazyLoad<string> _Unicode;
|
||||
public string Unicode
|
||||
@ -3072,24 +3080,34 @@ namespace VEPROMS.CSLA.Library
|
||||
return LazyLoad(ref _Size, "@Size");
|
||||
}
|
||||
}
|
||||
//public override string GetPDDisplayName()
|
||||
//{ return Unicode; }
|
||||
//public override string GetPDDescription()
|
||||
//{ return string.Format("Replace '{0}' with '{1}'", Unicode, Replace); }
|
||||
//public override string GetPDCategory()
|
||||
//{ return "Chars to Replace"; }
|
||||
//public override string ToString()
|
||||
//{
|
||||
// return Replace;
|
||||
//}
|
||||
public override string GetPDDisplayName()
|
||||
{ return Unicode; }
|
||||
public override string GetPDDescription()
|
||||
{ return string.Format("Replace '{0}' with '{1}'", Unicode, Replace); }
|
||||
public override string GetPDCategory()
|
||||
{ return "Chars to Replace"; }
|
||||
public override string ToString()
|
||||
{
|
||||
return Replace;
|
||||
}
|
||||
}
|
||||
|
||||
#endregion
|
||||
#region ReplaceSymbolCharList
|
||||
[TypeConverter(typeof(vlnListConverter<ReplaceSymbolCharList, ReplaceChar>))]
|
||||
public class ReplaceSymbolCharList : vlnFormatList<ReplaceChar>
|
||||
[TypeConverter(typeof(vlnIndexedListConverter<ReplaceSymbolCharList, ReplaceChar>))]
|
||||
public class ReplaceSymbolCharList : vlnIndexedFormatList<ReplaceChar>
|
||||
{
|
||||
public ReplaceSymbolCharList(XmlNodeList xmlNodeList) : base(xmlNodeList) { }
|
||||
public ReplaceSymbolCharList(XmlNodeList xmlNodeList, IFormatOrFormatInfo myFormat) : base(xmlNodeList, myFormat) { }
|
||||
public override vlnIndexedFormatList<ReplaceChar> InheritedList
|
||||
{
|
||||
get
|
||||
{
|
||||
IFormatOrFormatInfo parentFormat = MyFormat.MyIParent;
|
||||
if (parentFormat != null)
|
||||
return parentFormat.PlantFormat.FormatData.SectData.ReplaceSymbolCharList;
|
||||
return null;
|
||||
}
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
#region StepSectionLayoutData
|
||||
|
Loading…
x
Reference in New Issue
Block a user