Fixed scrollbar slider when the scrollbar is too small
Removed unused variable