Magnetism and superconductivity of new heavy fermion compounds CeTIn$_5$ (T=Co, Rh and Ir) are investigated by applying fluctuation exchange approximation to an orbital degenerate Hubbard model. The superconducting phase with $d_{x^2-y^2}$-symmetry is found to appear next to the antiferromagnetic phase with increasing the orbital splitting energy. The present theory suggests that the orbital splitting energy plays a key role of controlling parameter for the quantum phase transitions in the heavy fermion system.