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

Side by Side Diff: ui/views/ime/mock_input_method.cc

Issue 29943002: Limit display of the virtual keyboard to state changes triggered from a user gesture. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix ash_unittests Created 6 years, 11 months 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 | Annotate | Revision Log
« no previous file with comments | « ui/views/ime/mock_input_method.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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/views/ime/mock_input_method.h" 5 #include "ui/views/ime/mock_input_method.h"
6 6
7 #include "base/basictypes.h" 7 #include "base/basictypes.h"
8 #include "base/logging.h" 8 #include "base/logging.h"
9 #include "ui/base/ime/text_input_client.h" 9 #include "ui/base/ime/text_input_client.h"
10 #include "ui/events/event.h" 10 #include "ui/events/event.h"
(...skipping 112 matching lines...) Expand 10 before | Expand all | Expand 10 after
123 } 123 }
124 124
125 bool MockInputMethod::IsActive() { 125 bool MockInputMethod::IsActive() {
126 return active_; 126 return active_;
127 } 127 }
128 128
129 bool MockInputMethod::IsCandidatePopupOpen() const { 129 bool MockInputMethod::IsCandidatePopupOpen() const {
130 return false; 130 return false;
131 } 131 }
132 132
133 void MockInputMethod::ShowImeIfNeeded() {
134 }
135
133 bool MockInputMethod::IsMock() const { 136 bool MockInputMethod::IsMock() const {
134 return true; 137 return true;
135 } 138 }
136 139
137 void MockInputMethod::OnWillChangeFocus(View* focused_before, View* focused) { 140 void MockInputMethod::OnWillChangeFocus(View* focused_before, View* focused) {
138 ui::TextInputClient* client = GetTextInputClient(); 141 ui::TextInputClient* client = GetTextInputClient();
139 if (client && client->HasCompositionText()) 142 if (client && client->HasCompositionText())
140 client->ConfirmCompositionText(); 143 client->ConfirmCompositionText();
141 focus_changed_ = true; 144 focus_changed_ = true;
142 ClearResult(); 145 ClearResult();
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
180 input_locale_changed_ = false; 183 input_locale_changed_ = false;
181 } 184 }
182 185
183 void MockInputMethod::ClearResult() { 186 void MockInputMethod::ClearResult() {
184 composition_.Clear(); 187 composition_.Clear();
185 composition_changed_ = false; 188 composition_changed_ = false;
186 result_text_.clear(); 189 result_text_.clear();
187 } 190 }
188 191
189 } // namespace views 192 } // namespace views
OLDNEW
« no previous file with comments | « ui/views/ime/mock_input_method.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698