| 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 cf252a470c622c660f63d45890cee5bf7025ecb8..751378db499bbba4b916cf57df7821634c424017 100644
|
| --- a/chrome/browser/chromeos/base/locale_util.h
|
| +++ b/chrome/browser/chromeos/base/locale_util.h
|
| @@ -21,14 +21,24 @@ class Callback;
|
| 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.
|
| -// Arguments:
|
| +// |result| contains:
|
| // 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 std::string&, const std::string&, bool)>
|
| +typedef base::Callback<void(const LanguageSwitchResult& result)>
|
| SwitchLanguageCallback;
|
|
|
| // This function updates input methods only if requested. In general, you want
|
| @@ -41,7 +51,7 @@ typedef base::Callback<void(const std::string&, const std::string&, bool)>
|
| void SwitchLanguage(const std::string& locale,
|
| const bool enable_locale_keyboard_layouts,
|
| const bool login_layouts_only,
|
| - scoped_ptr<SwitchLanguageCallback> callback);
|
| + const SwitchLanguageCallback& callback);
|
|
|
| } // namespace locale_util
|
| } // namespace chromeos
|
|
|