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 #include "ui/base/ime/mock_input_method.h" | 5 #include "ui/base/ime/mock_input_method.h" |
6 | 6 |
7 namespace ui { | 7 namespace ui { |
8 | 8 |
9 MockInputMethod::MockInputMethod(internal::InputMethodDelegate* delegate) | 9 MockInputMethod::MockInputMethod(internal::InputMethodDelegate* delegate) |
10 : text_input_client_(NULL) { | 10 : text_input_client_(NULL) { |
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
76 } | 76 } |
77 | 77 |
78 base::i18n::TextDirection MockInputMethod::GetInputTextDirection() { | 78 base::i18n::TextDirection MockInputMethod::GetInputTextDirection() { |
79 return base::i18n::UNKNOWN_DIRECTION; | 79 return base::i18n::UNKNOWN_DIRECTION; |
80 } | 80 } |
81 | 81 |
82 bool MockInputMethod::IsActive() { | 82 bool MockInputMethod::IsActive() { |
83 return true; | 83 return true; |
84 } | 84 } |
85 | 85 |
86 ui::TextInputType MockInputMethod::GetTextInputType() const { | 86 TextInputType MockInputMethod::GetTextInputType() const { |
87 return ui::TEXT_INPUT_TYPE_NONE; | 87 return TEXT_INPUT_TYPE_NONE; |
| 88 } |
| 89 |
| 90 TextInputMode MockInputMethod::GetTextInputMode() const { |
| 91 return TEXT_INPUT_MODE_DEFAULT; |
88 } | 92 } |
89 | 93 |
90 bool MockInputMethod::CanComposeInline() const { | 94 bool MockInputMethod::CanComposeInline() const { |
91 return true; | 95 return true; |
92 } | 96 } |
93 | 97 |
94 bool MockInputMethod::IsCandidatePopupOpen() const { | 98 bool MockInputMethod::IsCandidatePopupOpen() const { |
95 return false; | 99 return false; |
96 } | 100 } |
97 | 101 |
98 void MockInputMethod::AddObserver(InputMethodObserver* observer) { | 102 void MockInputMethod::AddObserver(InputMethodObserver* observer) { |
99 observer_list_.AddObserver(static_cast<Observer*>(observer)); | 103 observer_list_.AddObserver(static_cast<Observer*>(observer)); |
100 } | 104 } |
101 | 105 |
102 void MockInputMethod::RemoveObserver(InputMethodObserver* observer) { | 106 void MockInputMethod::RemoveObserver(InputMethodObserver* observer) { |
103 observer_list_.RemoveObserver(static_cast<Observer*>(observer)); | 107 observer_list_.RemoveObserver(static_cast<Observer*>(observer)); |
104 } | 108 } |
105 | 109 |
106 } // namespace ui | 110 } // namespace ui |
OLD | NEW |