Keep the selected languages at segment change

Fix #11118