Implement serialization of Settings and SettingsRepository.
- FIX: Stile werden jetzt gespeichert.
This commit is contained in:
@ -19,6 +19,7 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Runtime.Serialization;
|
||||
using System.Text;
|
||||
|
||||
namespace zaaReloaded2.Controller.Elements
|
||||
@ -27,7 +28,8 @@ namespace zaaReloaded2.Controller.Elements
|
||||
/// Selects the time points of the last day in a given Formatter
|
||||
/// object.
|
||||
/// </summary>
|
||||
class SelectLastDay : ControlElementBase
|
||||
[Serializable]
|
||||
public class SelectLastDay : ControlElementBase, ISerializable
|
||||
{
|
||||
public override string Label
|
||||
{
|
||||
@ -39,6 +41,13 @@ namespace zaaReloaded2.Controller.Elements
|
||||
formatter.ProcessLastDay(this);
|
||||
}
|
||||
|
||||
protected override ElementBase CreateInstance()
|
||||
{
|
||||
return new SelectLastDay(CloneChildren());
|
||||
}
|
||||
|
||||
#region Constructors
|
||||
|
||||
public SelectLastDay() : base() { }
|
||||
|
||||
public SelectLastDay(FormatElementBase formatElement)
|
||||
@ -49,9 +58,13 @@ namespace zaaReloaded2.Controller.Elements
|
||||
: base(formatElements)
|
||||
{ }
|
||||
|
||||
protected override ElementBase CreateInstance()
|
||||
{
|
||||
return new SelectLastDay(CloneChildren());
|
||||
}
|
||||
/// <summary>
|
||||
/// Deserialization constructor.
|
||||
/// </summary>
|
||||
protected SelectLastDay(SerializationInfo info, StreamingContext context)
|
||||
: base(info, context)
|
||||
{ }
|
||||
|
||||
#endregion
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user