public static StartSymbol CreateStartSymbol(EditingContext context) { StartSymbol start = new StartSymbol(); FakeRoot fakeRoot = new FakeRoot { StartNode = new StartNode() }; ModelTreeManager manager = context.Services.GetService<ModelTreeManager>(); start.ModelItem = new FakeModelItemImpl(manager, typeof(FakeRoot), fakeRoot, null).Properties["StartNode"].Value; start.Name = "StartSymbol"; start.Focusable = true; start.Context = context; start.DataContext = start; return start; }
public static StartSymbol CreateStartSymbol(EditingContext context) { StartSymbol start = new StartSymbol(); FakeRoot fakeRoot = new FakeRoot { StartNode = new StartNode() }; ModelTreeManager manager = context.Services.GetService <ModelTreeManager>(); start.ModelItem = new FakeModelItemImpl(manager, typeof(FakeRoot), fakeRoot, null).Properties["StartNode"].Value; start.Name = "StartSymbol"; start.Focusable = true; start.Context = context; start.DataContext = start; return(start); }