private void UpdateDisplayChart()
        {
            TimerChart displayChart = UserData.GetChartViaIndex(chartIndex);

            ChartDateDisplay.Content = displayChart.recordedDate.ToLongDateString();

            ProgramDisplay[] displayArray = new ProgramDisplay[programs.Length + 1];
            lock (programs)
            {
                for (int i = 0; i < programs.Length; i++)
                {
                    displayArray[i] = new ProgramDisplay(programs[i].customName, displayChart.GetProgramTime(programs[i]));
                }
                displayArray[displayArray.Length - 1] = new ProgramDisplay("All Applications", displayChart.GetTotalTime());
            }

            MainDisplay.ItemsSource = displayArray;
        }
Beispiel #2
0
        public IActionResult Get()
        {
            var timerManager = new TimerChart(() => _hubContext.Clients.All.SendAsync("transferchartdata", DataManager.GetData()));

            return(Ok(new { Message = "Request Completed" }));
        }