Consider the following (well known) lemma (form the book Brownian Motion of Schilling) :
Lemma 1 : Let $X$ being $\mathcal X$ measurable, $Y$ being $\mathcal Y$ measurable and $\mathcal X$ and $\mathcal Y$ independent. If $\Phi:\mathbb R^2\to \mathbb R$ is bounded and measurable, then $$\mathbb E[\Phi(X,Y)\mid \mathcal X]=\mathbb E[\Phi(x,Y)]|_{x=X}=\mathbb E[\Phi(X,Y)\mid X].$$
And it's written below that a direct consequence of lemma 1 is
Corollary 1: Under the hypothesis of Lemma 1, $$\mathbb E[\Phi(X,Y)]=\int_{\mathbb R}\mathbb E[\Phi(x,Y)]\mathbb P\{X\in dx\}=\mathbb E\int_{\mathbb R}\Phi(x,Y)\mathbb P\{X\in dx\}.$$
Question : In what the corollary 1 is a related in any how to Lemma 1 ? Indeed,
\begin{align*} \mathbb E[\Phi(X,Y)]&=\int_{\mathbb R}\int_{\mathbb R}\Phi(x,y)\mathbb P\{X\in dx, Y\in dy\}\\ &\underset{(1)}{=}\int_{\mathbb R}\underbrace{\int_{\mathbb R}\Phi(x,y)\mathbb P\{Y\in dy\}}_{=\mathbb E[\Phi(x,Y)]}\mathbb P\{X\in dx\}\\ &=\int_{\mathbb R}\mathbb E[\Phi(x,Y)]\mathbb P\{X\in dx\}\\ &\underset{(2)}{=}\mathbb E\int_{\mathbb R}\Phi(x,Y)\mathbb P\{X\in dx\}, \end{align*}
where $(1)$ comes from independence of $X$ and $Y$ and $(2)$ follow by Fubini.
Where do I use lemma 1 here ?