add some more controls on translate code.