示例#1
0
        private void UpdateStats(StatsReporter reporter)
        {
            UpdateLabels(
                (int)reporter.GetTotalActiveToday(DateTime.Now.Date).Round(100.ms()).TotalSeconds,
                (int)reporter.GetLastInactiveTimespan().Round(100.ms()).TotalSeconds
                );

            ActivityPeriod currentActivityPeriod = reporter.GetCurrentLogicalPeriod();

            UpdateNotifyIcon(currentActivityPeriod is ActivePeriod, (int)currentActivityPeriod.Length.TotalMinutes);
            UpdateAlldayIcon(reporter.GetTotalActiveToday(DateTime.Now.Date));
            UpdateHistoryWindow();
        }
示例#2
0
 protected void AssertTotalActive(TimeSpan expected)
 {
     Assert.AreEqual(expected, statsReporter.GetTotalActiveToday(simulationStart));
 }