Fix a few bugs related to clicking and scrolling.