public KJIcon Clone() { KJIcon obj = (KJIcon)this.MemberwiseClone(); obj.ListTuYuan = new ArrayList(); foreach (CBase nIcon in ListTuYuan) { obj.ListTuYuan.Add(nIcon); } return(obj); }
public static KJIcon CreateKJIcon(string sName) { KJIcon newObj = new KJIcon(sName); if (newObj.LoadFromXML()) { return(newObj); } else { return(null); } }
public static void AddKJIcon(string sName) { foreach (KJIcon nIcon in ListKJIcon) { if (sName == nIcon.IconName) { return; } } KJIcon newIcon = CreateKJIcon(sName); if (newIcon != null) { ListKJIcon.Add(newIcon); } }