diff options
author | pkasting@chromium.org <pkasting@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-12-11 19:20:26 +0000 |
---|---|---|
committer | pkasting@chromium.org <pkasting@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-12-11 19:20:26 +0000 |
commit | 1ffed9387c38f75fe7ff13ec54a3cf893005b103 (patch) | |
tree | f87bf6b3ff3fb5b746b380b3cf209df2790c1971 /chrome/browser/render_view_context_menu.cc | |
parent | 1d0d8f176df9f7a9043a825541d016189754a27e (diff) | |
download | chromium_src-1ffed9387c38f75fe7ff13ec54a3cf893005b103.zip chromium_src-1ffed9387c38f75fe7ff13ec54a3cf893005b103.tar.gz chromium_src-1ffed9387c38f75fe7ff13ec54a3cf893005b103.tar.bz2 |
Try and make some spellcheck code more obvious by using typedefs.
I am not convinced this patch is a net win. Please share your thoughts on if using a Language/Languages set of types is better or worse than what we're doing now.
Review URL: http://codereview.chromium.org/13367
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@6807 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/render_view_context_menu.cc')
-rw-r--r-- | chrome/browser/render_view_context_menu.cc | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/chrome/browser/render_view_context_menu.cc b/chrome/browser/render_view_context_menu.cc index 75bc4d8..9634197 100644 --- a/chrome/browser/render_view_context_menu.cc +++ b/chrome/browser/render_view_context_menu.cc @@ -151,15 +151,15 @@ void RenderViewContextMenu::AppendEditableItems() { l10n_util::GetString(IDS_CONTENT_CONTEXT_SPELLCHECK_MENU)); // Add Spell Check languages to sub menu. - std::vector<std::wstring> language_vector; + SpellChecker::Languages display_languages; SpellChecker::GetSpellCheckLanguagesToDisplayInContextMenu(profile_, - &language_vector); - DCHECK(language_vector.size() < + &display_languages); + DCHECK(display_languages.size() < IDC_SPELLCHECK_LANGUAGES_LAST - IDC_SPELLCHECK_LANGUAGES_FIRST); const std::wstring app_locale = g_browser_process->GetApplicationLocale(); - for (size_t i = 0; i < language_vector.size(); ++i) { + for (size_t i = 0; i < display_languages.size(); ++i) { std::wstring local_language(l10n_util::GetLocalName( - language_vector[i], app_locale, true)); + display_languages[i], app_locale, true)); spellchecker_sub_menu_->AppendMenuItem( IDC_SPELLCHECK_LANGUAGES_FIRST + i, local_language, RADIO); } |