mouse lock checking improved