OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 #ifndef UI_BASE_IME_WIN_TSF_INPUT_SCOPE_H_ | 5 #ifndef UI_BASE_IME_WIN_TSF_INPUT_SCOPE_H_ |
6 #define UI_BASE_IME_WIN_TSF_INPUT_SCOPE_H_ | 6 #define UI_BASE_IME_WIN_TSF_INPUT_SCOPE_H_ |
7 | 7 |
8 #include <Windows.h> | 8 #include <Windows.h> |
9 | 9 |
10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
| 11 #include "ui/base/ime/text_input_mode.h" |
11 #include "ui/base/ime/text_input_type.h" | 12 #include "ui/base/ime/text_input_type.h" |
12 #include "ui/base/ui_export.h" | 13 #include "ui/base/ui_export.h" |
13 | 14 |
14 struct ITfInputScope; | 15 struct ITfInputScope; |
15 | 16 |
16 namespace ui { | 17 namespace ui { |
17 namespace tsf_inputscope { | 18 namespace tsf_inputscope { |
18 | 19 |
19 // Returns an instance of ITfInputScope, which is the Windows-specific | 20 // Returns an instance of ITfInputScope, which is the Windows-specific |
20 // category representation corresponding to ui::TextInputType that we are | 21 // category representation corresponding to ui::TextInputType that we are |
21 // using to specify the expected text type in the target field. | 22 // using to specify the expected text type in the target field. |
22 // The returned instance has 0 reference count. The caller must maintain its | 23 // The returned instance has 0 reference count. The caller must maintain its |
23 // reference count. | 24 // reference count. |
24 UI_EXPORT ITfInputScope* CreateInputScope(TextInputType text_input_type); | 25 UI_EXPORT ITfInputScope* CreateInputScope(TextInputType text_input_type); |
25 | 26 |
26 // A wrapper of the SetInputScope API exported by msctf.dll. | 27 // A wrapper of the SetInputScopes API exported by msctf.dll. |
27 // http://msdn.microsoft.com/en-us/library/windows/desktop/ms629025.aspx | 28 // http://msdn.microsoft.com/en-us/library/windows/desktop/ms629026.aspx |
28 // Does nothing on Windows XP in case TSF is disabled. | 29 // Does nothing on Windows XP in case TSF is disabled. |
29 // NOTE: For TSF-aware window, you should use ITfInputScope instead. | 30 // NOTE: For TSF-aware window, you should use ITfInputScope instead. |
30 UI_EXPORT void SetInputScopeForTsfUnawareWindow( | 31 UI_EXPORT void SetInputScopeForTsfUnawareWindow( |
31 HWND window_handle, | 32 HWND window_handle, |
32 TextInputType text_input_type); | 33 TextInputType text_input_type, |
| 34 TextInputMode text_input_mode); |
33 | 35 |
34 } // namespace tsf_inputscope | 36 } // namespace tsf_inputscope |
35 } // namespace ui | 37 } // namespace ui |
36 | 38 |
37 #endif // UI_BASE_IME_WIN_TSF_INPUT_SCOPE_H_ | 39 #endif // UI_BASE_IME_WIN_TSF_INPUT_SCOPE_H_ |
OLD | NEW |