slider: fix to restrict handle values when set programmatically.Fixed #3762-Slider: handles not restricted properly when set programmatically