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

Side by Side Diff: chrome/browser/chromeos/input_method/input_method_manager.h

Issue 10834108: Replace InputMethodEngineIBus. (Closed) Base URL: http://git.chromium.org/chromium/src.git@input_method_engine_ibus
Patch Set: Fix wrong DCHECK and it's description Created 8 years, 4 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 unified diff | Download patch
OLDNEW
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 7
8 #include <map> 8 #include <map>
9 #include <string> 9 #include <string>
10 #include <vector>
10 11
11 #include "base/logging.h" // for NOTIMPLEMENTED() 12 #include "base/logging.h" // for NOTIMPLEMENTED()
12 #include "chrome/browser/chromeos/input_method/input_method_config.h" 13 #include "chrome/browser/chromeos/input_method/input_method_config.h"
13 #include "chrome/browser/chromeos/input_method/input_method_descriptor.h" 14 #include "chrome/browser/chromeos/input_method/input_method_descriptor.h"
14 #include "chrome/browser/chromeos/input_method/input_method_property.h" 15 #include "chrome/browser/chromeos/input_method/input_method_property.h"
15 #include "chrome/browser/chromeos/input_method/input_method_util.h" 16 #include "chrome/browser/chromeos/input_method/input_method_util.h"
16 17
17 namespace ui { 18 namespace ui {
18 class Accelerator; 19 class Accelerator;
19 } // namespace ui 20 } // namespace ui
20 21
21 namespace chromeos { 22 namespace chromeos {
23 class InputMethodEngine;
22 namespace input_method { 24 namespace input_method {
23 25
24 class XKeyboard; 26 class XKeyboard;
25 27
26 // This class manages input methodshandles. Classes can add themselves as 28 // This class manages input methodshandles. Classes can add themselves as
27 // observers. Clients can get an instance of this library class by: 29 // observers. Clients can get an instance of this library class by:
28 // InputMethodManager::GetInstance(). 30 // InputMethodManager::GetInstance().
29 class InputMethodManager { 31 class InputMethodManager {
30 public: 32 public:
31 enum State { 33 enum State {
(...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after
109 // system input method framework as needed. 111 // system input method framework as needed.
110 virtual bool EnableInputMethods( 112 virtual bool EnableInputMethods(
111 const std::vector<std::string>& new_active_input_method_ids) = 0; 113 const std::vector<std::string>& new_active_input_method_ids) = 0;
112 114
113 // Updates a configuration of a system input method engine with |value|. 115 // Updates a configuration of a system input method engine with |value|.
114 // Returns true if the configuration is correctly set. 116 // Returns true if the configuration is correctly set.
115 virtual bool SetInputMethodConfig(const std::string& section, 117 virtual bool SetInputMethodConfig(const std::string& section,
116 const std::string& config_name, 118 const std::string& config_name,
117 const InputMethodConfigValue& value) = 0; 119 const InputMethodConfigValue& value) = 0;
118 120
119 // Adds an input method extension. 121 // Adds an input method extension. This function does not takes ownership of
122 // |instance|.
120 virtual void AddInputMethodExtension(const std::string& id, 123 virtual void AddInputMethodExtension(const std::string& id,
121 const std::string& name, 124 const std::string& name,
122 const std::vector<std::string>& layouts, 125 const std::vector<std::string>& layouts,
123 const std::string& language) = 0; 126 const std::string& language,
127 InputMethodEngine* instance) = 0;
124 128
125 // Removes an input method extension. 129 // Removes an input method extension.
126 virtual void RemoveInputMethodExtension(const std::string& id) = 0; 130 virtual void RemoveInputMethodExtension(const std::string& id) = 0;
127 131
128 // Gets the descriptor of the input method which is currently selected. 132 // Gets the descriptor of the input method which is currently selected.
129 virtual InputMethodDescriptor GetCurrentInputMethod() const = 0; 133 virtual InputMethodDescriptor GetCurrentInputMethod() const = 0;
130 134
131 // Gets the list of input method properties. The list could be empty(). 135 // Gets the list of input method properties. The list could be empty().
132 virtual InputMethodPropertyList GetCurrentInputMethodProperties() const = 0; 136 virtual InputMethodPropertyList GetCurrentInputMethodProperties() const = 0;
133 137
(...skipping 30 matching lines...) Expand all
164 168
165 // Gets the global instance. Initialize() or InitializeForTesting() must be 169 // Gets the global instance. Initialize() or InitializeForTesting() must be
166 // called first. 170 // called first.
167 static InputMethodManager* GetInstance(); 171 static InputMethodManager* GetInstance();
168 }; 172 };
169 173
170 } // namespace input_method 174 } // namespace input_method
171 } // namespace chromeos 175 } // namespace chromeos
172 176
173 #endif // CHROME_BROWSER_CHROMEOS_INPUT_METHOD_INPUT_METHOD_MANAGER_H_ 177 #endif // CHROME_BROWSER_CHROMEOS_INPUT_METHOD_INPUT_METHOD_MANAGER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698