Bug 1024887 - Move language related code to a separate module