[+] 补丁可选功能

This commit is contained in:
huiyadanli
2020-07-18 21:02:06 +08:00
parent 5a99342f61
commit 56842e911d
12 changed files with 192 additions and 43 deletions
+13 -1
View File
@@ -24,12 +24,24 @@ namespace RevokeMsgPatcher.Model
o.StartVersion = StartVersion;
o.EndVersion = EndVersion;
List<ReplacePattern> cs = new List<ReplacePattern>();
foreach(ReplacePattern c in ReplacePatterns)
foreach (ReplacePattern c in ReplacePatterns)
{
cs.Add(c.Clone());
}
o.ReplacePatterns = cs;
return o;
}
public List<string> GetCategories()
{
if (ReplacePatterns != null && ReplacePatterns.Count > 0)
{
return ReplacePatterns.Select(p => p.Category).ToList();
}
else
{
return new List<string>();
}
}
}
}
+2
View File
@@ -8,6 +8,8 @@ namespace RevokeMsgPatcher.Model
public byte[] Replace { get; set; }
public string Category { get; set; }
public ReplacePattern Clone()
{
ReplacePattern o = new ReplacePattern();