Fixed Regression causing scroll on mouse click

(Sorry about the commits and reverts - I am new to Git and did not want to introduce unnecessary changes in the pull which  I have on my branch)