Implements line mouse clicks correctly without painting in iteration.
Also corrects implementation of mouse click for point.