public static void CompetitionData(CompetitionWithResult compdata) { App.Current.Dispatcher.Invoke((Action) delegate { JudgePage currentPage = App.MainWindowRef.Main.Content as JudgePage; currentPage.compdata = compdata; }); }
public static void PagePainter(int jumpnumber) { App.Current.Dispatcher.Invoke((Action) delegate { JudgePage currentPage = App.MainWindowRef.Main.Content as JudgePage; if (jumpnumber > currentPage.compdata.Jumps.Count) { currentPage.CompOver.IsOpen = true; } Jump j = currentPage.compdata.Jumps.FirstOrDefault(x => x.GlobalNumber == jumpnumber); User u = currentPage.compdata.Comp.Users.FirstOrDefault(x => x.ID == j.CUID); currentPage.jumperNameHeader.Text = u.Name; currentPage.jumpSpecificsHeader.Text = "Jump " + j.Number + " - " + j.Name + " " + j.Code + "Difficulty " + j.Difficulty; currentPage.jumpIDSecretBox.Text = j.ID.ToString(); }); }