load / save burned state

This commit is contained in:
Tim Young 2018-02-14 12:07:06 +00:00
parent de0e9b4b98
commit 24413ec12e

View File

@ -32,6 +32,7 @@ namespace EduNetworkBuilder
public bool MustUseDHCP = false;
public bool CanAddNics = false;
public bool HasAdvFirewall = false;
public bool IsBurned = false;
public Color BackgroundColor = Color.Empty;
protected Color MorphColor = Color.Empty;
public List<FirewallRule> FirewallRules = new List<FirewallRule>();
@ -369,6 +370,9 @@ namespace EduNetworkBuilder
case "isdns":
bool.TryParse(Individual.InnerText, out isDNSServer);
break;
case "isburned":
bool.TryParse(Individual.InnerText, out IsBurned);
break;
case "isdhcp":
bool.TryParse(Individual.InnerText, out isDHCPServer);
break;
@ -409,7 +413,9 @@ namespace EduNetworkBuilder
writer.WriteElementString("mytype", myType.ToString());
writer.WriteElementString("isdns", isDNSServer.ToString());
writer.WriteElementString("isdhcp", isDHCPServer.ToString());
if(HasAdvFirewall)
if(IsBurned)
writer.WriteElementString("isburned", IsBurned.ToString());
if (HasAdvFirewall)
writer.WriteElementString("hasadvfirewall", HasAdvFirewall.ToString());
if (MorphColor != Color.Empty)
writer.WriteElementString("morphcolor", MorphColor.Name);