Ieditor.AddCustomView(new Button() { Name = "buttonView", Content = "Custom View", Height = 70, Width = 100, Background = new SolidColorBrush(Colors.Green) }, new |
Var tempStream = Ieditor.SaveEdits(); |
public class CustomController : DeserializationController
{
public override FrameworkElement GetCustomView(string name)
{
if (name == "buttonView")
return (new Button() { Name = "buttonView", Content = "Custom View", Height = 70, Width = 100, Background = new SolidColorBrush(Colors.Green) });
return null;
}
}
|
CustomController controller = new CustomController();
if (tempStream != null)
Ieditor.LoadEdits(tempStream, controller); |