BookmarkManager: Fix 'new folder text field size changes on clicking it' issue.
[chromium-blink-merge.git] / chrome / browser / chromeos / input_method / mock_input_method_engine.cc
blob852a095772f88901423338c1315cbedaa54f409d
1 // Copyright 2014 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.
5 #include "chrome/browser/chromeos/input_method/mock_input_method_engine.h"
7 #include <map>
9 namespace chromeos {
11 MockInputMethodEngine::MockInputMethodEngine() {}
13 MockInputMethodEngine::~MockInputMethodEngine() {}
15 const std::string& MockInputMethodEngine::GetActiveComponentId() const {
16 return active_component_id_;
19 bool MockInputMethodEngine::SetComposition(
20 int context_id,
21 const char* text,
22 int selection_start,
23 int selection_end,
24 int cursor,
25 const std::vector<SegmentInfo>& segments,
26 std::string* error) {
27 return true;
30 bool MockInputMethodEngine::ClearComposition(int context_id,
31 std::string* error) {
32 return true;
35 bool MockInputMethodEngine::CommitText(int context_id,
36 const char* text,
37 std::string* error) {
38 return true;
41 bool MockInputMethodEngine::SendKeyEvents(
42 int context_id,
43 const std::vector<KeyboardEvent>& events) {
44 return true;
47 const MockInputMethodEngine::CandidateWindowProperty&
48 MockInputMethodEngine::GetCandidateWindowProperty() const {
49 return candidate_window_property_;
52 void MockInputMethodEngine::SetCandidateWindowProperty(
53 const CandidateWindowProperty& property) {
56 bool MockInputMethodEngine::SetCandidateWindowVisible(bool visible,
57 std::string* error) {
58 return true;
61 bool MockInputMethodEngine::SetCandidates(
62 int context_id,
63 const std::vector<Candidate>& candidates,
64 std::string* error) {
65 return true;
68 bool MockInputMethodEngine::SetCursorPosition(int context_id,
69 int candidate_id,
70 std::string* error) {
71 return true;
74 bool MockInputMethodEngine::SetMenuItems(const std::vector<MenuItem>& items) {
75 return true;
78 bool MockInputMethodEngine::UpdateMenuItems(
79 const std::vector<MenuItem>& items) {
80 return true;
83 bool MockInputMethodEngine::IsActive() const {
84 return true;
87 bool MockInputMethodEngine::DeleteSurroundingText(int context_id,
88 int offset,
89 size_t number_of_chars,
90 std::string* error) {
91 return true;
94 void MockInputMethodEngine::HideInputView() {
97 void MockInputMethodEngine::FocusIn(
98 const IMEEngineHandlerInterface::InputContext& input_context) {
101 void MockInputMethodEngine::FocusOut() {
104 void MockInputMethodEngine::Enable(const std::string& component_id) {
105 active_component_id_ = component_id;
108 void MockInputMethodEngine::Disable() {
109 active_component_id_.clear();
112 void MockInputMethodEngine::PropertyActivate(const std::string& property_name) {
113 last_activated_property_ = property_name;
116 void MockInputMethodEngine::Reset() {
119 bool MockInputMethodEngine::IsInterestedInKeyEvent() const {
120 return true;
123 void MockInputMethodEngine::ProcessKeyEvent(
124 const ui::KeyEvent& key_event,
125 const KeyEventDoneCallback& callback) {
128 void MockInputMethodEngine::CandidateClicked(uint32 index) {
131 void MockInputMethodEngine::SetSurroundingText(const std::string& text,
132 uint32 cursor_pos,
133 uint32 anchor_pos,
134 uint32 offset_pos) {}
136 void MockInputMethodEngine::SetCompositionBounds(
137 const std::vector<gfx::Rect>& bounds) {
140 } // namespace chromeos