Fix text input of characters from east-asian languages (issue #152).

git-svn-id: https://chromiumembedded.googlecode.com/svn/trunk@151 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
This commit is contained in:
Marshall Greenblatt 2010-12-09 17:30:49 +00:00
parent 871a8a7770
commit 173fb79550
1 changed files with 6 additions and 1 deletions

View File

@ -113,7 +113,6 @@ LRESULT CALLBACK WebWidgetHost::WndProc(HWND hwnd, UINT message, WPARAM wparam,
host->CaptureLostEvent();
break;
// TODO(darin): add WM_SYSKEY{DOWN/UP} to capture ALT key actions
case WM_KEYDOWN:
case WM_KEYUP:
case WM_SYSKEYDOWN:
@ -123,6 +122,12 @@ LRESULT CALLBACK WebWidgetHost::WndProc(HWND hwnd, UINT message, WPARAM wparam,
host->KeyEvent(message, wparam, lparam);
break;
// Necessary for text input of characters from east-asian languages. Do
// not pass to DefWindowProc or characters will be displayed twice.
case WM_IME_CHAR:
host->KeyEvent(message, wparam, lparam);
return 0;
case WM_SETFOCUS:
host->SetFocus(true);
break;