Slider: implemented _getClosestHandleIndex

Refines logic to determine which handle should be selected when handles
overlap.