Commit 28130abb authored by My Nguyen's avatar My Nguyen Committed by Commit Bot

[DeleteIt] Remove unused GetAcceptLanguageList, GetCurrentKeyboardLayout

There's no reference to these methods.
GetAcceptLanguageList()
Added in https://crrev.com/397723002
Usage removed in https://crrev.com/c/602884 (file deleted)

GetCurrentKeyboardLayout()
Added in https://crrev.com/417103003
Usage removed in https://crrev.com/c/907973

Bug: none
Change-Id: I068165ffb17f3e024027e03263476d0acd4a595c
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2473859Reviewed-by: default avatarToni Baržić <tbarzic@chromium.org>
Commit-Queue: My Nguyen <myy@chromium.org>
Cr-Commit-Position: refs/heads/master@{#818599}
parent cb0e96dc
...@@ -496,18 +496,6 @@ std::string FindMostRelevantLocale( ...@@ -496,18 +496,6 @@ std::string FindMostRelevantLocale(
return fallback_locale; return fallback_locale;
} }
std::unique_ptr<base::ListValue> GetAcceptLanguageList() {
// Collect the language codes from the supported accept-languages.
const std::string app_locale = g_browser_process->GetApplicationLocale();
std::vector<std::string> accept_language_codes;
l10n_util::GetAcceptLanguagesForLocale(app_locale, &accept_language_codes);
return GetLanguageList(
*input_method::InputMethodManager::Get()->GetSupportedInputMethods(),
accept_language_codes,
StartupCustomizationDocument::GetInstance()->configured_locales(),
false);
}
std::unique_ptr<base::ListValue> GetAndActivateLoginKeyboardLayouts( std::unique_ptr<base::ListValue> GetAndActivateLoginKeyboardLayouts(
const std::string& locale, const std::string& locale,
const std::string& selected, const std::string& selected,
...@@ -593,13 +581,4 @@ void GetKeyboardLayoutsForLocale( ...@@ -593,13 +581,4 @@ void GetKeyboardLayoutsForLocale(
base::BindOnce(&GetKeyboardLayoutsForResolvedLocale, locale, callback)); base::BindOnce(&GetKeyboardLayoutsForResolvedLocale, locale, callback));
} }
std::unique_ptr<base::DictionaryValue> GetCurrentKeyboardLayout() {
const input_method::InputMethodDescriptor current_input_method =
input_method::InputMethodManager::Get()
->GetActiveIMEState()
->GetCurrentInputMethod();
return CreateInputMethodsEntry(current_input_method,
current_input_method.id());
}
} // namespace chromeos } // namespace chromeos
...@@ -14,7 +14,6 @@ ...@@ -14,7 +14,6 @@
#include "chrome/browser/chromeos/base/locale_util.h" #include "chrome/browser/chromeos/base/locale_util.h"
namespace base { namespace base {
class DictionaryValue;
class ListValue; class ListValue;
} }
...@@ -66,13 +65,6 @@ std::string FindMostRelevantLocale( ...@@ -66,13 +65,6 @@ std::string FindMostRelevantLocale(
const base::ListValue& available_locales, const base::ListValue& available_locales,
const std::string& fallback_locale); const std::string& fallback_locale);
// Return a list of supported accept languages. The listed languages can be used
// in the Accept-Language header. The return value will look like:
// [{'code': 'fi', 'displayName': 'Finnish', 'nativeDisplayName': 'suomi'}, ...]
// The most relevant languages, read from initial_locale in VPD, will be first
// in the list.
std::unique_ptr<base::ListValue> GetAcceptLanguageList();
// Return a list of keyboard layouts that can be used for |locale| on the login // Return a list of keyboard layouts that can be used for |locale| on the login
// screen. Each list entry is a dictionary that contains data such as an ID and // screen. Each list entry is a dictionary that contains data such as an ID and
// a display name. The list will consist of the device's hardware layouts, // a display name. The list will consist of the device's hardware layouts,
...@@ -100,10 +92,6 @@ void GetKeyboardLayoutsForLocale( ...@@ -100,10 +92,6 @@ void GetKeyboardLayoutsForLocale(
const GetKeyboardLayoutsForLocaleCallback& callback, const GetKeyboardLayoutsForLocaleCallback& callback,
const std::string& locale); const std::string& locale);
// Returns the current keyboard layout, expressed as a dictionary that contains
// data such as an ID and a display name.
std::unique_ptr<base::DictionaryValue> GetCurrentKeyboardLayout();
} // namespace chromeos } // namespace chromeos
#endif // CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_L10N_UTIL_H_ #endif // CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_L10N_UTIL_H_
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment