Modified to avoid getText method's weird behavior.
Improved LocaleSelectorAction.