Translate: Bug fix: need to normalize the language code for Translate UI
commit9d44ab25f44f4343e9b3ccfe7c9a4227a3cb26d0
authortoyoshim@chromium.org <toyoshim@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>
Mon, 9 Jun 2014 11:11:53 +0000 (9 11:11 +0000)
committertoyoshim@chromium.org <toyoshim@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>
Mon, 9 Jun 2014 11:11:53 +0000 (9 11:11 +0000)
tree81107dba765a9bf138cfe254d54bc47fed3f90dc
parentdde9dfdee84407b91d8fab67418a4b8fc6fe2b91
Translate: Bug fix: need to normalize the language code for Translate UI

Take over this CL from hajimehoshi@chromium.org, and just rebase the CL
to trunk.

Original description by hajimehoshi@ follows;

Before passing the language code to Translate UI, this must be
normalized (like 'hi-IN' -> 'hi').

I mistakenly droped this process when moving GetTranslateLanguages from
translate_bubble_view.cc to translate_tab_helper.cc
(https://codereview.chromium.org/203223002) :-(

BUG=380137
R=toyoshim@chromium.org
TBR=hajimehoshi@chromium.org

Review URL: https://codereview.chromium.org/322733002

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@275786 0039d316-1c4b-4281-b951-d872f2087c98
chrome/browser/translate/chrome_translate_client.cc