changes of properties in ExpandableObjectConverter not updating
I'm using ExpandableObjectConverter to group a collection of properties.
it shows fine in the properties window, but the changes doesn't show in the *.Designer.cs file
so every time the desiner is refreshed all my changes gone.
what am I doing wrong?
Code:
[TypeConverter(typeof(ExpandableObjectConverter))]
public class HeaderAppereance
{
public HeaderAppereance(Control parent)
{
this.Parent = parent;
}
private Control Parent;
private Color backcolor;
public Color BackColor
{
get { return this.backcolor; }
set { this.backcolor = value; Parent.Refresh(); }
}
....
}
Code:
public class MyCustomControl : Panel,StyleNamesFinder
{
public MyCustomControl ()
{
this.Header = new HeaderAppereance(this);
....
}
public HeaderAppereance Header { get; set; }
}