Improved functionality of the grid size slider.