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

Side by Side Diff: chrome/browser/spellchecker/spellcheck_host.cc

Issue 10573017: Rename SpellCheckCommon namespace to chrome. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix Created 8 years, 6 months 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 | « no previous file | chrome/browser/spellchecker/spellcheck_host_browsertest.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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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/browser/spellchecker/spellcheck_host.h" 5 #include "chrome/browser/spellchecker/spellcheck_host.h"
6 6
7 #include "base/string_split.h" 7 #include "base/string_split.h"
8 #include "base/synchronization/waitable_event.h" 8 #include "base/synchronization/waitable_event.h"
9 #include "chrome/browser/prefs/pref_member.h" 9 #include "chrome/browser/prefs/pref_member.h"
10 #include "chrome/browser/profiles/profile.h" 10 #include "chrome/browser/profiles/profile.h"
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after
64 spellcheck_mac::GetAvailableLanguages(&accept_languages); 64 spellcheck_mac::GetAvailableLanguages(&accept_languages);
65 else 65 else
66 base::SplitString(accept_languages_pref.GetValue(), ',', &accept_languages); 66 base::SplitString(accept_languages_pref.GetValue(), ',', &accept_languages);
67 #else 67 #else
68 base::SplitString(accept_languages_pref.GetValue(), ',', &accept_languages); 68 base::SplitString(accept_languages_pref.GetValue(), ',', &accept_languages);
69 #endif // !OS_MACOSX 69 #endif // !OS_MACOSX
70 70
71 for (std::vector<std::string>::const_iterator i = accept_languages.begin(); 71 for (std::vector<std::string>::const_iterator i = accept_languages.begin();
72 i != accept_languages.end(); ++i) { 72 i != accept_languages.end(); ++i) {
73 std::string language = 73 std::string language =
74 SpellCheckCommon::GetCorrespondingSpellCheckLanguage(*i); 74 chrome::spellcheck_common::GetCorrespondingSpellCheckLanguage(*i);
75 if (!language.empty() && 75 if (!language.empty() &&
76 std::find(languages->begin(), languages->end(), language) == 76 std::find(languages->begin(), languages->end(), language) ==
77 languages->end()) { 77 languages->end()) {
78 languages->push_back(language); 78 languages->push_back(language);
79 } 79 }
80 } 80 }
81 81
82 for (size_t i = 0; i < languages->size(); ++i) { 82 for (size_t i = 0; i < languages->size(); ++i) {
83 if ((*languages)[i] == dictionary_language) 83 if ((*languages)[i] == dictionary_language)
84 return i; 84 return i;
(...skipping 20 matching lines...) Expand all
105 } 105 }
106 106
107 // static 107 // static
108 SpellCheckHost::EventType SpellCheckHost::WaitStatusEvent() { 108 SpellCheckHost::EventType SpellCheckHost::WaitStatusEvent() {
109 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); 109 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
110 110
111 if (g_status_event) 111 if (g_status_event)
112 g_status_event->Wait(); 112 g_status_event->Wait();
113 return g_status_type; 113 return g_status_type;
114 } 114 }
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/spellchecker/spellcheck_host_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698