• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 // Copyright 2013 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 #include "ui/base/ime/dummy_text_input_client.h"
6 #include "ui/gfx/rect.h"
7 
8 namespace ui {
9 
DummyTextInputClient()10 DummyTextInputClient::DummyTextInputClient()
11     : text_input_type_(TEXT_INPUT_TYPE_NONE) {}
12 
DummyTextInputClient(TextInputType text_input_type)13 DummyTextInputClient::DummyTextInputClient(TextInputType text_input_type)
14     : text_input_type_(text_input_type) {}
15 
~DummyTextInputClient()16 DummyTextInputClient::~DummyTextInputClient() {
17 }
18 
SetCompositionText(const CompositionText & composition)19 void DummyTextInputClient::SetCompositionText(
20     const CompositionText& composition) {
21 }
22 
ConfirmCompositionText()23 void DummyTextInputClient::ConfirmCompositionText() {
24 }
25 
ClearCompositionText()26 void DummyTextInputClient::ClearCompositionText() {
27 }
28 
InsertText(const base::string16 & text)29 void DummyTextInputClient::InsertText(const base::string16& text) {
30 }
31 
InsertChar(base::char16 ch,int flags)32 void DummyTextInputClient::InsertChar(base::char16 ch, int flags) {
33 }
34 
GetAttachedWindow() const35 gfx::NativeWindow DummyTextInputClient::GetAttachedWindow() const {
36   return NULL;
37 }
38 
GetTextInputType() const39 TextInputType DummyTextInputClient::GetTextInputType() const {
40   return text_input_type_;
41 }
42 
GetTextInputMode() const43 TextInputMode DummyTextInputClient::GetTextInputMode() const {
44   return TEXT_INPUT_MODE_DEFAULT;
45 }
46 
CanComposeInline() const47 bool DummyTextInputClient::CanComposeInline() const {
48   return false;
49 }
50 
GetCaretBounds() const51 gfx::Rect DummyTextInputClient::GetCaretBounds() const {
52   return gfx::Rect();
53 }
54 
GetCompositionCharacterBounds(uint32 index,gfx::Rect * rect) const55 bool DummyTextInputClient::GetCompositionCharacterBounds(
56     uint32 index,
57     gfx::Rect* rect) const {
58   return false;
59 }
60 
HasCompositionText() const61 bool DummyTextInputClient::HasCompositionText() const {
62   return false;
63 }
64 
GetTextRange(gfx::Range * range) const65 bool DummyTextInputClient::GetTextRange(gfx::Range* range) const {
66   return false;
67 }
68 
GetCompositionTextRange(gfx::Range * range) const69 bool DummyTextInputClient::GetCompositionTextRange(gfx::Range* range) const {
70   return false;
71 }
72 
GetSelectionRange(gfx::Range * range) const73 bool DummyTextInputClient::GetSelectionRange(gfx::Range* range) const {
74   return false;
75 }
76 
SetSelectionRange(const gfx::Range & range)77 bool DummyTextInputClient::SetSelectionRange(const gfx::Range& range) {
78   return false;
79 }
80 
DeleteRange(const gfx::Range & range)81 bool DummyTextInputClient::DeleteRange(const gfx::Range& range) {
82   return false;
83 }
84 
GetTextFromRange(const gfx::Range & range,base::string16 * text) const85 bool DummyTextInputClient::GetTextFromRange(const gfx::Range& range,
86                                             base::string16* text) const {
87   return false;
88 }
89 
OnInputMethodChanged()90 void DummyTextInputClient::OnInputMethodChanged() {
91 }
92 
ChangeTextDirectionAndLayoutAlignment(base::i18n::TextDirection direction)93 bool DummyTextInputClient::ChangeTextDirectionAndLayoutAlignment(
94     base::i18n::TextDirection direction) {
95   return false;
96 }
97 
ExtendSelectionAndDelete(size_t before,size_t after)98 void DummyTextInputClient::ExtendSelectionAndDelete(size_t before,
99                                                     size_t after) {
100 }
101 
EnsureCaretInRect(const gfx::Rect & rect)102 void DummyTextInputClient::EnsureCaretInRect(const gfx::Rect& rect)  {
103 }
104 
OnCandidateWindowShown()105 void DummyTextInputClient::OnCandidateWindowShown() {
106 }
107 
OnCandidateWindowUpdated()108 void DummyTextInputClient::OnCandidateWindowUpdated() {
109 }
110 
OnCandidateWindowHidden()111 void DummyTextInputClient::OnCandidateWindowHidden() {
112 }
113 
IsEditingCommandEnabled(int command_id)114 bool DummyTextInputClient::IsEditingCommandEnabled(int command_id) {
115   return false;
116 }
117 
ExecuteEditingCommand(int command_id)118 void DummyTextInputClient::ExecuteEditingCommand(int command_id) {
119 }
120 
121 }  // namespace ui
122