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

Unified Diff: chrome/browser/chromeos/base/locale_util.h

Issue 664503003: Revert of Revert of Revert of ChromeOS NetworkScreenHandler should not call CheckAndResolveLocale on UI thread. (patchs… (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 2 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | chrome/browser/chromeos/base/locale_util.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/chromeos/base/locale_util.h
diff --git a/chrome/browser/chromeos/base/locale_util.h b/chrome/browser/chromeos/base/locale_util.h
index 751378db499bbba4b916cf57df7821634c424017..cf252a470c622c660f63d45890cee5bf7025ecb8 100644
--- a/chrome/browser/chromeos/base/locale_util.h
+++ b/chrome/browser/chromeos/base/locale_util.h
@@ -21,24 +21,14 @@
namespace chromeos {
namespace locale_util {
-struct LanguageSwitchResult {
- LanguageSwitchResult(const std::string& requested_locale,
- const std::string& loaded_locale,
- bool success);
-
- std::string requested_locale;
- std::string loaded_locale;
- bool success;
-};
-
// This callback is called on UI thread, when ReloadLocaleResources() is
// completed on BlockingPool.
-// |result| contains:
+// Arguments:
// locale - (copy of) locale argument to SwitchLanguage(). Expected locale.
// loaded_locale - actual locale name loaded.
// success - if locale load succeeded.
// (const std::string* locale, const std::string* loaded_locale, bool success)
-typedef base::Callback<void(const LanguageSwitchResult& result)>
+typedef base::Callback<void(const std::string&, const std::string&, bool)>
SwitchLanguageCallback;
// This function updates input methods only if requested. In general, you want
@@ -51,7 +41,7 @@
void SwitchLanguage(const std::string& locale,
const bool enable_locale_keyboard_layouts,
const bool login_layouts_only,
- const SwitchLanguageCallback& callback);
+ scoped_ptr<SwitchLanguageCallback> callback);
} // namespace locale_util
} // namespace chromeos
« no previous file with comments | « no previous file | chrome/browser/chromeos/base/locale_util.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698