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

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

Issue 67313006: Delete IBusClient. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 7 years, 1 month 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_ENGINE_IBUS_H_ 5 #ifndef CHROME_BROWSER_CHROMEOS_INPUT_METHOD_INPUT_METHOD_ENGINE_IBUS_H_
6 #define CHROME_BROWSER_CHROMEOS_INPUT_METHOD_INPUT_METHOD_ENGINE_IBUS_H_ 6 #define CHROME_BROWSER_CHROMEOS_INPUT_METHOD_INPUT_METHOD_ENGINE_IBUS_H_
7 7
8 #include <map> 8 #include <map>
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after
95 virtual void SetSurroundingText(const std::string& text, uint32 cursor_pos, 95 virtual void SetSurroundingText(const std::string& text, uint32 cursor_pos,
96 uint32 anchor_pos) OVERRIDE; 96 uint32 anchor_pos) OVERRIDE;
97 97
98 // Called when the connection with ibus-daemon is connected. 98 // Called when the connection with ibus-daemon is connected.
99 void OnConnected(); 99 void OnConnected();
100 100
101 // Called whtn the connection with ibus-daemon is disconnected. 101 // Called whtn the connection with ibus-daemon is disconnected.
102 void OnDisconnected(); 102 void OnDisconnected();
103 103
104 private: 104 private:
105 // Returns true if the connection to ibus-daemon is avaiable.
106 bool IsConnected();
107
108 // Converts MenuItem to InputMethodProperty. 105 // Converts MenuItem to InputMethodProperty.
109 void MenuItemToProperty(const MenuItem& item, 106 void MenuItemToProperty(const MenuItem& item,
110 input_method::InputMethodProperty* property); 107 input_method::InputMethodProperty* property);
111 108
112 // Registers the engine component. 109 // Registers the engine component.
113 void RegisterComponent(); 110 void RegisterComponent();
114 111
115 // Called when the RegisterComponent is failed.
116 void OnComponentRegistrationFailed();
117
118 // Called when the RegisterComponent is succeeded.
119 void OnComponentRegistered();
120
121 // Called when the ibus-daemon sends CreateEngine message with corresponding 112 // Called when the ibus-daemon sends CreateEngine message with corresponding
122 // engine id. 113 // engine id.
123 void CreateEngineHandler( 114 void CreateEngineHandler(
124 const IBusEngineFactoryService::CreateEngineResponseSender& sender); 115 const IBusEngineFactoryService::CreateEngineResponseSender& sender);
125 116
126 // Returns current IBusEngineService, if there is no available service, this 117 // Returns current IBusEngineService, if there is no available service, this
127 // function returns NULL. 118 // function returns NULL.
128 IBusEngineService* GetCurrentService(); 119 IBusEngineService* GetCurrentService();
129 120
130 // True if the current context has focus. 121 // True if the current context has focus.
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after
180 scoped_ptr<IBusEngineService> ibus_engine_service_; 171 scoped_ptr<IBusEngineService> ibus_engine_service_;
181 scoped_ptr<IBusEngineFactoryService> ibus_engine_factory_service_; 172 scoped_ptr<IBusEngineFactoryService> ibus_engine_factory_service_;
182 173
183 // Used for making callbacks. 174 // Used for making callbacks.
184 base::WeakPtrFactory<InputMethodEngineIBus> weak_ptr_factory_; 175 base::WeakPtrFactory<InputMethodEngineIBus> weak_ptr_factory_;
185 }; 176 };
186 177
187 } // namespace chromeos 178 } // namespace chromeos
188 179
189 #endif // CHROME_BROWSER_CHROMEOS_INPUT_METHOD_INPUT_METHOD_ENGINE_IBUS_H_ 180 #endif // CHROME_BROWSER_CHROMEOS_INPUT_METHOD_INPUT_METHOD_ENGINE_IBUS_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698