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 CHROME_BROWSER_CHROMEOS_INPUT_METHOD_INPUT_METHOD_MANAGER_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_INPUT_METHOD_INPUT_METHOD_MANAGER_H_ |
6 #define CHROME_BROWSER_CHROMEOS_INPUT_METHOD_INPUT_METHOD_MANAGER_H_ | 6 #define CHROME_BROWSER_CHROMEOS_INPUT_METHOD_INPUT_METHOD_MANAGER_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include <map> | 9 #include <map> |
10 #include <set> | 10 #include <set> |
(...skipping 20 matching lines...) Expand all Loading... |
31 | 31 |
32 class HotkeyManager; | 32 class HotkeyManager; |
33 class VirtualKeyboard; | 33 class VirtualKeyboard; |
34 class XKeyboard; | 34 class XKeyboard; |
35 | 35 |
36 // This class manages input methodshandles. Classes can add themselves as | 36 // This class manages input methodshandles. Classes can add themselves as |
37 // observers. Clients can get an instance of this library class by: | 37 // observers. Clients can get an instance of this library class by: |
38 // InputMethodManager::GetInstance(). | 38 // InputMethodManager::GetInstance(). |
39 class InputMethodManager { | 39 class InputMethodManager { |
40 public: | 40 public: |
41 enum State { | |
42 STATE_LOGIN_SCREEN = 0, | |
43 // The user entered the correct password (= NOTIFICATION_LOGIN_USER_CHANGED | |
44 // has been sent), but NOTIFICATION_SESSION_STARTED has not. | |
45 STATE_LOGGING_IN, | |
46 // The browser window for user session is ready. | |
47 STATE_BROWSER_SCREEN, | |
48 STATE_LOCK_SCREEN, | |
49 STATE_TERMINATING, | |
50 }; | |
51 | |
52 class Observer { | 41 class Observer { |
53 public: | 42 public: |
54 virtual ~Observer() {} | 43 virtual ~Observer() {} |
55 | 44 |
56 // Called when the current input method is changed. | 45 // Called when the current input method is changed. |
57 virtual void InputMethodChanged( | 46 virtual void InputMethodChanged( |
58 InputMethodManager* manager, | 47 InputMethodManager* manager, |
59 const InputMethodDescriptor& current_input_method, | 48 const InputMethodDescriptor& current_input_method, |
60 size_t num_active_input_methods) = 0; | 49 size_t num_active_input_methods) = 0; |
61 | 50 |
(...skipping 217 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
279 virtual InputMethodDescriptor GetPreviousInputMethod() const = 0; | 268 virtual InputMethodDescriptor GetPreviousInputMethod() const = 0; |
280 virtual InputMethodDescriptor GetCurrentInputMethod() const = 0; | 269 virtual InputMethodDescriptor GetCurrentInputMethod() const = 0; |
281 | 270 |
282 virtual InputMethodPropertyList GetCurrentInputMethodProperties() const = 0; | 271 virtual InputMethodPropertyList GetCurrentInputMethodProperties() const = 0; |
283 }; | 272 }; |
284 | 273 |
285 } // namespace input_method | 274 } // namespace input_method |
286 } // namespace chromeos | 275 } // namespace chromeos |
287 | 276 |
288 #endif // CHROME_BROWSER_CHROMEOS_INPUT_METHOD_INPUT_METHOD_MANAGER_H_ | 277 #endif // CHROME_BROWSER_CHROMEOS_INPUT_METHOD_INPUT_METHOD_MANAGER_H_ |
OLD | NEW |