Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(69)

Side by Side Diff: chrome/common/spellcheck_common.cc

Issue 11365057: Revert 165562 - Bump English spellcheck dictionary versions and add tests (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « DEPS ('k') | chrome/renderer/spellchecker/spellcheck_unittest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/common/spellcheck_common.h" 5 #include "chrome/common/spellcheck_common.h"
6 6
7 #include "base/file_path.h" 7 #include "base/file_path.h"
8 8
9 namespace chrome { 9 namespace chrome {
10 namespace spellcheck_common { 10 namespace spellcheck_common {
(...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after
98 {"pl-PL", "-1-3"}, 98 {"pl-PL", "-1-3"},
99 {"fr-FR", "-2-0"}, // 2-0 (2010): upgraded dictionaries. 99 {"fr-FR", "-2-0"}, // 2-0 (2010): upgraded dictionaries.
100 {"hu-HU", "-2-0"}, 100 {"hu-HU", "-2-0"},
101 {"ro-RO", "-2-0"}, 101 {"ro-RO", "-2-0"},
102 {"ru-RU", "-2-0"}, 102 {"ru-RU", "-2-0"},
103 {"bg-BG", "-2-0"}, 103 {"bg-BG", "-2-0"},
104 {"sr", "-2-0"}, 104 {"sr", "-2-0"},
105 {"uk-UA", "-2-0"}, 105 {"uk-UA", "-2-0"},
106 {"pt-BR", "-2-2"}, // 2-2 (Mar 2011): upgraded a dictionary. 106 {"pt-BR", "-2-2"}, // 2-2 (Mar 2011): upgraded a dictionary.
107 {"sh", "-2-2"}, // 2-2 (Mar 2011): added a dictionary. 107 {"sh", "-2-2"}, // 2-2 (Mar 2011): added a dictionary.
108 {"en-US", "-2-3"}, // 2-3 (May 2012): fixed affixes + more words.
109 {"en-CA", "-2-3"},
110 {"en-GB", "-2-3"},
111 {"en-AU", "-2-3"},
108 {"ca-ES", "-2-3"}, // 2-3 (May 2012): upgraded a dictionary. 112 {"ca-ES", "-2-3"}, // 2-3 (May 2012): upgraded a dictionary.
109 {"sv-SE", "-2-3"}, // 2-3 (May 2012): upgraded a dictionary. 113 {"sv-SE", "-2-3"}, // 2-3 (May 2012): upgraded a dictionary.
110 {"af-ZA", "-2-3"}, // 2-3 (May 2012): added a dictionary. 114 {"af-ZA", "-2-3"}, // 2-3 (May 2012): added a dictionary.
111 {"fo-FO", "-2-3"}, // 2-3 (May 2012): added a dictionary. 115 {"fo-FO", "-2-3"}, // 2-3 (May 2012): added a dictionary.
112 {"en-US", "-2-4"}, // 2-4 (October 2012): add more words.
113 {"en-CA", "-2-4"},
114 {"en-GB", "-2-4"},
115 {"en-AU", "-2-4"},
116
117 }; 116 };
118 117
119 // Generate the bdict file name using default version string or special 118 // Generate the bdict file name using default version string or special
120 // version string, depending on the language. 119 // version string, depending on the language.
121 std::string language = GetSpellCheckLanguageRegion(input_language); 120 std::string language = GetSpellCheckLanguageRegion(input_language);
122 std::string versioned_bdict_file_name(language + kDefaultVersionString + 121 std::string versioned_bdict_file_name(language + kDefaultVersionString +
123 ".bdic"); 122 ".bdic");
124 for (size_t i = 0; i < ARRAYSIZE_UNSAFE(special_version_string); ++i) { 123 for (size_t i = 0; i < ARRAYSIZE_UNSAFE(special_version_string); ++i) {
125 if (language == special_version_string[i].language) { 124 if (language == special_version_string[i].language) {
126 versioned_bdict_file_name = 125 versioned_bdict_file_name =
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
174 173
175 void SpellCheckLanguages(std::vector<std::string>* languages) { 174 void SpellCheckLanguages(std::vector<std::string>* languages) {
176 for (size_t i = 0; i < ARRAYSIZE_UNSAFE(g_supported_spellchecker_languages); 175 for (size_t i = 0; i < ARRAYSIZE_UNSAFE(g_supported_spellchecker_languages);
177 ++i) { 176 ++i) {
178 languages->push_back(g_supported_spellchecker_languages[i].language); 177 languages->push_back(g_supported_spellchecker_languages[i].language);
179 } 178 }
180 } 179 }
181 180
182 } // namespace spellcheck_common 181 } // namespace spellcheck_common
183 } // namespace chrome 182 } // namespace chrome
OLDNEW
« no previous file with comments | « DEPS ('k') | chrome/renderer/spellchecker/spellcheck_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698