public BindableInt Set(T lookup, int value, int?min = null, int?max = null) { BindableInt bindable = GetBindable <int>(lookup) as BindableInt; if (bindable == null) { bindable = new BindableInt(value); addBindable(lookup, bindable); } else { bindable.Value = value; } if (min.HasValue) { bindable.MinValue = min.Value; } if (max.HasValue) { bindable.MaxValue = max.Value; } return(bindable); }
public BindableInt Set(T lookup, int value) { BindableInt bindable = GetBindable <int>(lookup) as BindableInt; if (bindable == null) { bindable = new BindableInt(value); addBindable(lookup, bindable); } else { bindable.Value = value; } return(bindable); }