Let $\phi : \mathbb R \rightarrow \mathbb R$ be a continuous function such that whenever $f_n \rightarrow f$ weakly in $L^2[0,1]$, we have $\phi\circ f_n \rightarrow \phi\circ f$ weakly in $L^2[0,1]$. I am trying to prove that $\phi$ must be an affine map, $\phi(x) = ax+b$ for some $a,b \in \mathbb R$. So far I've tried proving the contrapositive, or trying to show that $\phi'$ exists and is constant, but have had no success. Any suggestions?
Suppose there exist $t,s\in\mathbb R$ such that $\phi((s+t)/2)\ne (\phi(s)+\phi(t))/2$. Let $f_n$ take the values $s$ and $t$ in an alternating fashion: for example, $f_n=s$ on $[k/2^n,(k+1)/2^n)$ if $k$ is even, and $f_n=t$ if $k$ is odd. Observe that $f_n$ converge weakly to the constant function $(s+t)/2$, while $\phi\circ f_n$ converge weakly to the constant function $(\phi(s)+\phi(t))/2$.