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

Unified Diff: ui/base/ime/win/imm32_manager.cc

Issue 2445253002: Fix the issue that the CJK IMEs default mode on the Omnibox is Latin/English. (Closed)
Patch Set: Created 4 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 | « ui/base/ime/input_method_win.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/base/ime/win/imm32_manager.cc
diff --git a/ui/base/ime/win/imm32_manager.cc b/ui/base/ime/win/imm32_manager.cc
index b0420fdaa65fbd429f1cf668f9aa4e38f782607e..8b868ce51ca4c33d911ff3aa9c85aef6c511baf0 100644
--- a/ui/base/ime/win/imm32_manager.cc
+++ b/ui/base/ime/win/imm32_manager.cc
@@ -133,7 +133,8 @@ void IMM32Manager::SetInputLanguage() {
WCHAR keyboard_layout[KL_NAMELENGTH];
if (::GetKeyboardLayoutNameW(keyboard_layout)) {
input_language_id_ =
- static_cast<LANGID>(_wtoi(&keyboard_layout[KL_NAMELENGTH >> 1]));
+ static_cast<LANGID>(
+ wcstol(&keyboard_layout[KL_NAMELENGTH >> 1], nullptr, 16));
} else {
input_language_id_ = 0x0409; // Fallback to en-US.
}
« no previous file with comments | « ui/base/ime/input_method_win.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698