Add condition to mouseclick