SharpLibEar/Event.cs
changeset 262 c4749a27966d
parent 260 d44943088c67
child 265 82e87f4956ea
     1.1 --- a/SharpLibEar/Event.cs	Tue Aug 30 21:14:18 2016 +0200
     1.2 +++ b/SharpLibEar/Event.cs	Wed Aug 31 16:06:47 2016 +0200
     1.3 @@ -23,6 +23,10 @@
     1.4          ]
     1.5          public bool Enabled { get; set; } = true;
     1.6  
     1.7 +
     1.8 +        /// <summary>
     1.9 +        /// TODO: Should the name property be moved to our EAR Object?
    1.10 +        /// </summary>
    1.11          [DataMember]
    1.12          [AttributeObjectProperty
    1.13              (
    1.14 @@ -33,6 +37,7 @@
    1.15          ]
    1.16          public string Name { get; set; } = "";
    1.17  
    1.18 +
    1.19          [DataMember]
    1.20          public List<Action> Actions = new List<Action>();
    1.21  
    1.22 @@ -41,6 +46,12 @@
    1.23          {
    1.24              base.DoConstruct();
    1.25  
    1.26 +            //Make sure our name is not null
    1.27 +            if (Name == null)
    1.28 +            {
    1.29 +                Name = "";
    1.30 +            }
    1.31 +
    1.32              // TODO: Construct properties too
    1.33              foreach (Action a in Actions)
    1.34              {