In this article, we provide an alternative approach, based on mean-field theory, on establishing the pre-commitment optimal solution to the continuous time mean-variance portfolio selection problem. By considering the probability distribution of the underlying wealth process and introducing a suitable adjoint function, we show that the optimal control (pre-commitment solution) satisfies a HJB equation that also involves the probability distribution of the corresponding optimal wealth process, which naturally satisfies Kolmogorov's Forward Equation. For if the probability density function exists, it will also satisfy a Fokker-Planck (Kolmogorov's Backward Equation), and hence together with the mentioned HJB, the whole problem becomes a special problem in the theory of mean-field games. Solving by Ansatz, we further obtain the explicit optimal asset allocation, which coincides with that first obtained in the work of Li and Zhou (2000) [18].