responds to mouse clicks