private void ReStartSimulationClick(object sender, RoutedEventArgs e) { model = new Model(); model.InitSimpleModel(); s.model = model; Paint(); Thread t = new Thread(s.run); t.Start(); }
public MainWindow() { //CreateRunFolderAndInitPath(); model = new Model(); Points = new ObservableCollection <MyPoint>(); Lines = new ObservableCollection <MyLine>(); Rooms = new ObservableCollection <MyRoom>(); SimulationCosts = new ObservableCollection <Costs>(); LineAndCostActualStep = new ObservableCollection <LineAndCost>(); InitRoomTypes(); model.InitSimpleModel(); s.model = model; s.ModelChanged += ModelChangeHandler; DataContext = this; InitializeComponent(); Paint(); LoadDataFromModel(); }
private void initButton_Click(object sender, EventArgs e) { model = new Model(); model.InitSimpleModel(); Invalidate(); }
public SimulationForm() { InitializeComponent(); model.InitSimpleModel(); g = this.CreateGraphics(); }