Quantum phase transition of the one-dimensional compass model in a transverse magnetic field