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

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

Issue 111373008: Update some uses of char16 to use the base:: namespace. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 12 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/input_method_bridge.cc ('k') | url/url_test_utils.h » ('j') | 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 70 matching lines...) Expand 10 before | Expand all | Expand 10 after
81 if (handled) { 81 if (handled) {
82 if (result_text_.length()) 82 if (result_text_.length())
83 client->InsertText(result_text_); 83 client->InsertText(result_text_);
84 if (composition_changed_) { 84 if (composition_changed_) {
85 if (composition_.text.length()) 85 if (composition_.text.length())
86 client->SetCompositionText(composition_); 86 client->SetCompositionText(composition_);
87 else 87 else
88 client->ClearCompositionText(); 88 client->ClearCompositionText();
89 } 89 }
90 } else if (key.type() == ui::ET_KEY_PRESSED) { 90 } else if (key.type() == ui::ET_KEY_PRESSED) {
91 char16 ch = key.GetCharacter(); 91 base::char16 ch = key.GetCharacter();
92 client->InsertChar(ch, key.flags()); 92 client->InsertChar(ch, key.flags());
93 } 93 }
94 } 94 }
95 95
96 ClearResult(); 96 ClearResult();
97 } 97 }
98 98
99 void MockInputMethod::OnTextInputTypeChanged(View* view) { 99 void MockInputMethod::OnTextInputTypeChanged(View* view) {
100 if (IsViewFocused(view)) 100 if (IsViewFocused(view))
101 text_input_type_changed_ = true; 101 text_input_type_changed_ = true;
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after
180 input_locale_changed_ = false; 180 input_locale_changed_ = false;
181 } 181 }
182 182
183 void MockInputMethod::ClearResult() { 183 void MockInputMethod::ClearResult() {
184 composition_.Clear(); 184 composition_.Clear();
185 composition_changed_ = false; 185 composition_changed_ = false;
186 result_text_.clear(); 186 result_text_.clear();
187 } 187 }
188 188
189 } // namespace views 189 } // namespace views
OLDNEW
« no previous file with comments | « ui/views/ime/input_method_bridge.cc ('k') | url/url_test_utils.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698