added code to move slider bar