OLD | NEW |
---|---|
(Empty) | |
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 | |
3 // found in the LICENSE file. | |
4 | |
5 #ifndef CHROME_BROWSER_CHROMEOS_INPUT_METHOD_MOCK_IBUS_CONTROLLER_H_ | |
6 #define CHROME_BROWSER_CHROMEOS_INPUT_METHOD_MOCK_IBUS_CONTROLLER_H_ | |
7 #pragma once | |
8 | |
9 #include "chrome/browser/chromeos/input_method/ibus_controller_base.h" | |
10 | |
11 namespace chromeos { | |
12 namespace input_method { | |
13 | |
14 struct InputMethodConfigValue; | |
15 struct InputMethodProperty; | |
16 typedef std::vector<InputMethodProperty> InputMethodPropertyList; | |
kinaba
2012/04/16 10:22:53
InputMethodPropertyList is not used.
Yusuke Sato
2012/04/16 11:25:43
Done.
| |
17 | |
18 // Mock IBusController implementation. | |
19 class MockIBusController : public IBusControllerBase { | |
20 public: | |
21 MockIBusController(); | |
22 virtual ~MockIBusController(); | |
23 | |
24 // IBusController overrides: | |
25 virtual bool Start() OVERRIDE; | |
26 virtual bool Stop() OVERRIDE; | |
27 virtual bool ChangeInputMethod(const std::string& id) OVERRIDE; | |
28 virtual bool ActivateInputMethodProperty(const std::string& key) OVERRIDE; | |
29 #if defined(USE_VIRTUAL_KEYBOARD) | |
30 virtual void SendHandwritingStroke(const HandwritingStroke& stroke) OVERRIDE { | |
31 } | |
32 virtual void CancelHandwriting(int n_strokes) OVERRIDE { | |
33 } | |
34 #endif | |
35 | |
36 int start_count_; | |
37 bool start_return_; | |
38 int stop_count_; | |
39 bool stop_return_; | |
40 int change_input_method_count_; | |
41 std::string change_input_method_id_; | |
42 bool change_input_method_return_; | |
43 int activate_input_method_property_count_; | |
44 std::string activate_input_method_property_key_; | |
45 bool activate_input_method_property_return_; | |
46 int set_input_method_config_internal_count_; | |
47 ConfigKeyType set_input_method_config_internal_key_; | |
48 InputMethodConfigValue set_input_method_config_internal_value_; | |
49 bool set_input_method_config_internal_return_; | |
50 | |
51 protected: | |
52 // IBusControllerBase overrides: | |
53 virtual bool SetInputMethodConfigInternal( | |
54 const ConfigKeyType& key, | |
55 const InputMethodConfigValue& value) OVERRIDE; | |
56 | |
57 private: | |
58 DISALLOW_COPY_AND_ASSIGN(MockIBusController); | |
59 }; | |
60 | |
61 } // namespace input_method | |
62 } // namespace chromeos | |
63 | |
64 #endif // CHROME_BROWSER_CHROMEOS_INPUT_METHOD_MOCK_IBUS_CONTROLLER_H_ | |
OLD | NEW |