예제 #1
0
        public SliderViewModel(
            SliderConfiguration Configuration,
            IControlTuningService <SliderConfiguration> TuningService)
        {
            this.Configuration = Configuration;

            this.WhenAnyValue(x => x.UserValue,
                              x => x.Precision,
                              (v, p) => v.ToString("F" + p))
            .ToProperty(this, x => x.OutputValueString, out _outputValueString);

            Tune = ReactiveCommand.CreateFromTask(() => TuningService.Tune(this.Configuration));
            Tune.ObserveOnDispatcher()
            .BindTo(this, x => x.Configuration);

            Tune.IsExecuting
            .Select(x => !x)
            .ToProperty(this, x => x.IsEditable, out _isEditable);
        }
예제 #2
0
 static void sliderOnChange(SliderConfiguration e)
 {
     kendoConsole.log("Change :: new value is: " + e.value);
 }
예제 #3
0
 static void sliderOnSlide(SliderConfiguration e)
 {
     kendoConsole.log("Slide :: new slide value is: " + e.value);
 }
예제 #4
0
 static void sliderOnChange(SliderConfiguration e)
 {
     kendoConsole.log("Change :: new value is: " + e.value);
 }
예제 #5
0
 static void sliderOnSlide(SliderConfiguration e)
 {
     kendoConsole.log("Slide :: new slide value is: " + e.value);
 }
예제 #6
0
 public SliderViewModel CreateViewModel(SliderConfiguration Configuration)
 {
     return(new(Configuration, _tuningService));
 }