From 7a698427bf75a794859da9b9686450db91195f51 Mon Sep 17 00:00:00 2001 From: Shane Neuville Date: Sun, 8 Mar 2020 13:35:37 -0600 Subject: [PATCH] [WPF] Dont set Slider.Value if it already matches control (#9847) --- Xamarin.Forms.Platform.WPF/Renderers/SliderRenderer.cs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Xamarin.Forms.Platform.WPF/Renderers/SliderRenderer.cs b/Xamarin.Forms.Platform.WPF/Renderers/SliderRenderer.cs index 08986c7d8..19d5d3b09 100644 --- a/Xamarin.Forms.Platform.WPF/Renderers/SliderRenderer.cs +++ b/Xamarin.Forms.Platform.WPF/Renderers/SliderRenderer.cs @@ -60,7 +60,8 @@ namespace Xamarin.Forms.Platform.WPF void HandleValueChanged(object sender, RoutedPropertyChangedEventArgs routedPropertyChangedEventArgs) { - ((IElementController)Element).SetValueFromRenderer(Slider.ValueProperty, Control.Value); + if (Control.Value != Element.Value) + ((IElementController)Element).SetValueFromRenderer(Slider.ValueProperty, Control.Value); } bool _isDisposed;