public void window_OnResetStatisticsButtonPressed(HudWindow sender) { ResetAllStatistics(); sender.DisplayStatistics(GetStatistics()); }
public void Remove(HudWindow window) { Trace.Assert(window != null, "Trying to remove a null reference to a hud window"); window.Close(); windowsList.Remove(window); }
private void SetWindowLocation(HudWindow w, Point location) { w.Location = location; }
public void Add(HudWindow window) { windowsList.Add(window); }
/* The user requested that all statistics get reset */ public void window_OnResetAllStatisticsButtonPressed(HudWindow sender) { statistics.PrepareStatisticsForNewRound(); foreach (Player p in PlayerList) { p.ResetAllStatistics(); if (p.HudWindow != null) p.HudWindow.DisplayStatistics(p.GetStatistics()); // TODO: is this thread safe? } }