private void AcceptBtn_Click(object sender, EventArgs e) { if (ManualRB.Checked) { SystemController.GetInstance().ChangeRefreshStrategy(new ManualRefresh()); } else if (FixedItterRB.Checked) { SystemController.GetInstance().ChangeRefreshStrategy(new FixedItterationsRefresh(int.Parse(ItterCountTextBox.Text))); } else if (AutoRefreshRB.Checked) { SystemController.GetInstance().ChangeRefreshStrategy(new AutomaticRefresh()); } if (LogModelRB.Checked) { Counter.GetInstance().ChangeMathModel(new LogisticModel()); } else if (NPopModelRB.Checked) { Counter.GetInstance().ChangeMathModel(new N_SpaciesModel_General()); } Close(); }
private void SettingsWindow_Load(object sender, EventArgs e) { ItterCountTextBox.Enabled = false; switch (SystemController.GetInstance().GetRefreshMode().Name) { case "ManualRefresh": ManualRB.Checked = true; break; case "FixedItterationsRefresh": FixedItterRB.Checked = true; break; case "AutomaticRefresh": AutoRefreshRB.Checked = true; break; } switch (Counter.GetInstance().GetMathModel().Name) { case "LogisticModel": LogModelRB.Checked = true; break; case "N_SpaciesModel_General": NPopModelRB.Checked = true; break; } }
public static void Stop() { SystemController.GetInstance().StopRefresh(); }
public static void Execute() { SystemController.GetInstance().ExecuteRefresh(); }