Example #1
0
        private void UpdateUnitLabelText()
        {
            var value = this.TrackBar.Value;
            var e     = new SettingTrackBarValueConstructEventArgs(value);

            this.OnValueConstructor(e);

            var valueLabel    = this.ValueLabel;
            var valueToString = e.ValueToString ?? value.ToString();

            valueLabel.Text = string.Concat(valueToString, this.Unit);
        }
 private void OnTimeoutControlValueConstructor(object sender, SettingTrackBarValueConstructEventArgs e)
 {
     e.ValueToString = (e.Value / 1000.0D).ToString("F1");
 }
 private void OnServiceUnavailableSleepControlValueConstructor(object sender, SettingTrackBarValueConstructEventArgs e)
 {
     e.ValueToString = (e.Value / 1000.0D).ToString("F1");
 }
Example #4
0
 protected virtual void OnValueConstructor(SettingTrackBarValueConstructEventArgs e)
 {
     this.ValueConstructor?.Invoke(this, e);
 }