Пример #1
0
        void Timer_Tick(object sender, TickEventArgs e)
        {
            var time = string.Format("{0:00}:{1:00}", e.Time.Minutes, e.Time.Seconds);

            var snoozing = StateMachine.State == State.Snoozing;

            currentTimeToolStripMenuItem.Text      = snoozing ? (time + " (Snoozing)") : time;
            currentTimeToolStripMenuItem.ForeColor = e.Color == ShowTimeColor.Red ? Color.Red : Color.Black;

            notifyIcon1.Text = "You should stand up in " + TimeTranslator.Translate(e.Time);
        }
Пример #2
0
 void NotifyEnteredRedMode()
 {
     notifyIcon1.ShowBalloonTip(2000, "Prepair to stand up", "Stand-up time is getting close. So prepare to stand up in " + TimeTranslator.Translate(new TimeSpan(0, 0, Business.Settings.RedSeconds)), ToolTipIcon.Info);
 }
Пример #3
0
 public void ManualReset()
 {
     StateMachine.Reset();
     notifyIcon1.ShowBalloonTip(2000, "Timer has been reset", "You should stand-up in " + TimeTranslator.Translate(new TimeSpan(0, 0, StandUp.Business.Settings.TotalSeconds)), ToolTipIcon.Info);
 }