OLD | NEW |
---|---|
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "ui/base/ime/input_method_imm32.h" | 5 #include "ui/base/ime/input_method_imm32.h" |
6 | 6 |
7 #include "base/basictypes.h" | 7 #include "base/basictypes.h" |
8 #include "ui/base/ime/composition_text.h" | 8 #include "ui/base/ime/composition_text.h" |
9 #include "ui/base/ime/text_input_client.h" | 9 #include "ui/base/ime/text_input_client.h" |
10 #include "ui/base/ime/win/tsf_input_scope.h" | |
10 | 11 |
11 | 12 |
12 namespace ui { | 13 namespace ui { |
13 | 14 |
14 InputMethodIMM32::InputMethodIMM32(internal::InputMethodDelegate* delegate, | 15 InputMethodIMM32::InputMethodIMM32(internal::InputMethodDelegate* delegate, |
15 HWND toplevel_window_handle) | 16 HWND toplevel_window_handle) |
16 : InputMethodWin(delegate, toplevel_window_handle), | 17 : InputMethodWin(delegate, toplevel_window_handle), |
17 enabled_(false), is_candidate_popup_open_(false), | 18 enabled_(false), is_candidate_popup_open_(false), |
18 composing_window_handle_(NULL) { | 19 composing_window_handle_(NULL) { |
19 // In non-Aura environment, appropriate callbacks to OnFocus() and OnBlur() | 20 // In non-Aura environment, appropriate callbacks to OnFocus() and OnBlur() |
(...skipping 251 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
271 imm32_manager_.DisableIME(window_handle); | 272 imm32_manager_.DisableIME(window_handle); |
272 enabled_ = false; | 273 enabled_ = false; |
273 break; | 274 break; |
274 default: | 275 default: |
275 imm32_manager_.EnableIME(window_handle); | 276 imm32_manager_.EnableIME(window_handle); |
276 enabled_ = true; | 277 enabled_ = true; |
277 break; | 278 break; |
278 } | 279 } |
279 | 280 |
280 imm32_manager_.SetTextInputMode(window_handle, GetTextInputMode()); | 281 imm32_manager_.SetTextInputMode(window_handle, GetTextInputMode()); |
282 tsf_inputscope::SetInputScopeForTsfUnawareWindow( | |
283 window_handle, GetTextInputType(), GetTextInputMode()); | |
yoichio
2013/09/23 12:09:54
Can we cache values of GetTextInputType() and *Mod
yukawa
2013/09/23 17:54:21
I think we can in this particular case, although t
| |
281 } | 284 } |
282 | 285 |
283 } // namespace ui | 286 } // namespace ui |
OLD | NEW |