Example #1
0
        private void ClockStopped_event(object sender, ClockEventArgs e)
        {
            timeDisplayBox.DoValidation = true;

            RefreshTimeDisplay( );
            RefreshControls( );
        }
Example #2
0
        private void ClockStarted_event(object sender, ClockEventArgs e)
        {
            timeDisplayBox.DoValidation = false;

            if (DisplayVisible)
            {
                Program.TextRefresher.Handlers += refreshDisplayText;
            }

            RefreshControls( );
        }
Example #3
0
        private void clockSpeedChanged_event(object sender, ClockEventArgs args)
        {
            _refreshing = true;
            if (args.Speed >= 0)
            {
                countForwardOption.Active = true;
            }
            else
            {
                countBackwardOption.Active = true;
            }

            watchSpeedEntry.Value = Math.Abs(args.Speed);

            _refreshing = false;
        }
        /// <summary>
        /// Creates a log for when a clock has stopped ticking
        /// </summary>
        private void clockStopped_event(object sender, ClockEventArgs e)
        {
            string translatable, logDesc;

            if (e.Speed >= 0)
            {
                translatable = Catalog.GetString("Stopped ticking with {0}.");
            }
            else
            {
                translatable = Catalog.GetString("Stopped counting down with {0}.");
            }

            TimeSpan time = ApplyCap(e.DisplayTime);

            logDesc = string.Format(translatable, TimeFormatSettings.ToString(time));

            Logger.AddEntry(new LogEntry(_name, logDesc, e.Timestamp));
        }
Example #5
0
 private void ClockChangedSpeed_event(object sender, ClockEventArgs e)
 {
     RefreshControls();
 }