Exemplo n.º 1
0
        public void UpdateCurrentPos(TimeSpan timeSpent)
        {
            var maxTimeSpan = _config.MaxTimeSpan;
            if (timeSpent > maxTimeSpan) {
                timeSpent = maxTimeSpan;
            }

            _rectTimeSpent = new Rect(rctCurrent)
                             {
                                 Color = _config.TimeSpentColor,
                                 Width = GetPos(timeSpent.TotalMinutes/60.0)
                             };
        }
Exemplo n.º 2
0
 private void InitMinTimes(double minTimeStart)
 {
     _rectMinTime = new Rect(rctMinTime)
                    {
                        Margin = SetElementPos(GetPos(minTimeStart), rctMinTime),
                        Width = GetPos(_config.BreakTimeNum),
                        Visibility = true,
                        Color = _config.MinTimeColor
                    };
 }