Skip to content

Commit

Permalink
Fixed issue with SliderValue binding
Browse files Browse the repository at this point in the history
The slider value binding was setting minvalue
  • Loading branch information
grofit committed Apr 1, 2017
1 parent 165d6df commit 74b857f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/Assets/BindingsRx/Bindings/SliderExtensions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,10 @@ namespace BindingsRx.Bindings
public static class SliderExtensions
{
public static IDisposable BindValueTo(this Slider input, IReactiveProperty<float> property, BindingTypes bindingType = BindingTypes.Default, params IFilter<float>[] filters)
{ return GenericBindings.Bind(() => input.value, x => input.maxValue = x, property, bindingType, filters).AddTo(input); }
{ return GenericBindings.Bind(() => input.value, x => input.value = x, property, bindingType, filters).AddTo(input); }

public static IDisposable BindValueTo(this Slider input, Func<float> getter, Action<float> setter, BindingTypes bindingType = BindingTypes.Default, params IFilter<float>[] filters)
{ return GenericBindings.Bind(() => input.value, x => input.maxValue = x, getter, setter, bindingType, filters).AddTo(input); }
{ return GenericBindings.Bind(() => input.value, x => input.value = x, getter, setter, bindingType, filters).AddTo(input); }

public static IDisposable BindMaxValueTo(this Slider input, IReactiveProperty<float> property, BindingTypes bindingType = BindingTypes.Default, params IFilter<float>[] filters)
{ return GenericBindings.Bind(() => input.maxValue, x => input.maxValue = x, property, bindingType, filters).AddTo(input); }
Expand Down

0 comments on commit 74b857f

Please sign in to comment.