45 references to Slider
Microsoft.Maui.Controls (33)
Hosting\AppHostBuilderExtensions.cs (1)
82
handlersCollection.AddHandler<
Slider
, SliderHandler>();
PlatformConfiguration\iOSSpecific\Slider.cs (4)
4
using FormsElement = Maui.Controls.
Slider
;
25
public static bool GetUpdateOnTap(this IPlatformElementConfiguration<iOS,
FormsElement
> config)
31
public static IPlatformElementConfiguration<iOS,
FormsElement
> SetUpdateOnTap(this IPlatformElementConfiguration<iOS,
FormsElement
> config, bool value)
Properties\AssemblyInfo.cs (6)
153
[assembly: StyleProperty("-maui-min-track-color", typeof(
Slider
), nameof(
Slider
.MinimumTrackColorProperty))]
154
[assembly: StyleProperty("-maui-max-track-color", typeof(
Slider
), nameof(
Slider
.MaximumTrackColorProperty))]
155
[assembly: StyleProperty("-maui-thumb-color", typeof(
Slider
), nameof(
Slider
.ThumbColorProperty))]
Slider\Slider.cs (22)
9
public partial class Slider : View, ISliderController, IElementConfiguration<
Slider
>, ISlider
12
public static readonly BindableProperty MinimumProperty = BindableProperty.Create(nameof(Minimum), typeof(double), typeof(
Slider
), 0d, coerceValue: (bindable, value) =>
14
var
slider = (
Slider
)bindable;
20
public static readonly BindableProperty MaximumProperty = BindableProperty.Create(nameof(Maximum), typeof(double), typeof(
Slider
), 1d, coerceValue: (bindable, value) =>
22
var
slider = (
Slider
)bindable;
28
public static readonly BindableProperty ValueProperty = BindableProperty.Create(nameof(Value), typeof(double), typeof(
Slider
), 0d, BindingMode.TwoWay, coerceValue: (bindable, value) =>
30
var
slider = (
Slider
)bindable;
34
var
slider = (
Slider
)bindable;
39
public static readonly BindableProperty MinimumTrackColorProperty = BindableProperty.Create(nameof(MinimumTrackColor), typeof(Color), typeof(
Slider
), null);
42
public static readonly BindableProperty MaximumTrackColorProperty = BindableProperty.Create(nameof(MaximumTrackColor), typeof(Color), typeof(
Slider
), null);
45
public static readonly BindableProperty ThumbColorProperty = BindableProperty.Create(nameof(ThumbColor), typeof(Color), typeof(
Slider
), null);
48
public static readonly BindableProperty ThumbImageSourceProperty = BindableProperty.Create(nameof(ThumbImageSource), typeof(ImageSource), typeof(
Slider
), default(ImageSource));
51
public static readonly BindableProperty DragStartedCommandProperty = BindableProperty.Create(nameof(DragStartedCommand), typeof(ICommand), typeof(
Slider
), default(ICommand));
54
public static readonly BindableProperty DragCompletedCommandProperty = BindableProperty.Create(nameof(DragCompletedCommand), typeof(ICommand), typeof(
Slider
), default(ICommand));
56
readonly Lazy<PlatformConfigurationRegistry<
Slider
>> _platformConfigurationRegistry;
61
_platformConfigurationRegistry = new Lazy<PlatformConfigurationRegistry<
Slider
>>(() => new PlatformConfigurationRegistry<
Slider
>(this));
169
public IPlatformElementConfiguration<T,
Slider
> On<T>() where T : IConfigPlatform
Microsoft.Maui.Controls.Compatibility (12)
iOS\Renderers\SliderRenderer.cs (12)
13
public class SliderRenderer : ViewRenderer<
Slider
, UISlider>
59
protected override void OnElementChanged(ElementChangedEventArgs<
Slider
> e)
148
_ = this.ApplyNativeImageAsync(
Slider
.ThumbImageSourceProperty, uiimage =>
160
if (e.PropertyName ==
Slider
.MaximumProperty.PropertyName)
162
else if (e.PropertyName ==
Slider
.MinimumProperty.PropertyName)
164
else if (e.PropertyName ==
Slider
.ValueProperty.PropertyName)
166
else if (e.PropertyName ==
Slider
.MinimumTrackColorProperty.PropertyName)
168
else if (e.PropertyName ==
Slider
.MaximumTrackColorProperty.PropertyName)
170
else if (e.PropertyName ==
Slider
.ThumbImageSourceProperty.PropertyName)
172
else if (e.PropertyName ==
Slider
.ThumbColorProperty.PropertyName)
181
((IElementController)Element).SetValueFromRenderer(
Slider
.ValueProperty, Control.Value);
211
Element.SetValueFromRenderer(
Slider
.ValueProperty, val);