Replaces mouse click event