fix isMousePressed bug