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

Side by Side Diff: chrome/browser/chromeos/input_method/textinput_test_helper.cc

Issue 105193002: Replace string16 with base::string16. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years 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
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 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 "ash/shell.h" 5 #include "ash/shell.h"
6 #include "base/strings/string_number_conversions.h" 6 #include "base/strings/string_number_conversions.h"
7 #include "base/strings/string_util.h" 7 #include "base/strings/string_util.h"
8 #include "base/strings/utf_string_conversions.h" 8 #include "base/strings/utf_string_conversions.h"
9 #include "chrome/browser/chromeos/input_method/textinput_test_helper.h" 9 #include "chrome/browser/chromeos/input_method/textinput_test_helper.h"
10 #include "chrome/browser/ui/browser.h" 10 #include "chrome/browser/ui/browser.h"
(...skipping 127 matching lines...) Expand 10 before | Expand all | Expand 10 after
138 const gfx::Rect& expected_caret_rect, 138 const gfx::Rect& expected_caret_rect,
139 const gfx::Rect& expected_composition_head) { 139 const gfx::Rect& expected_composition_head) {
140 waiting_type_ = WAIT_ON_CARET_BOUNDS_CHANGED; 140 waiting_type_ = WAIT_ON_CARET_BOUNDS_CHANGED;
141 while (expected_caret_rect != caret_rect_ || 141 while (expected_caret_rect != caret_rect_ ||
142 expected_composition_head != composition_head_) 142 expected_composition_head != composition_head_)
143 content::RunMessageLoop(); 143 content::RunMessageLoop();
144 waiting_type_ = NO_WAIT; 144 waiting_type_ = NO_WAIT;
145 } 145 }
146 146
147 void TextInputTestHelper::WaitForSurroundingTextChanged( 147 void TextInputTestHelper::WaitForSurroundingTextChanged(
148 const string16& expected_text, 148 const base::string16& expected_text,
149 const gfx::Range& expected_selection) { 149 const gfx::Range& expected_selection) {
150 waiting_type_ = WAIT_ON_CARET_BOUNDS_CHANGED; 150 waiting_type_ = WAIT_ON_CARET_BOUNDS_CHANGED;
151 while (expected_text != surrounding_text_ || 151 while (expected_text != surrounding_text_ ||
152 expected_selection != selection_range_) 152 expected_selection != selection_range_)
153 content::RunMessageLoop(); 153 content::RunMessageLoop();
154 waiting_type_ = NO_WAIT; 154 waiting_type_ = NO_WAIT;
155 } 155 }
156 156
157 // static 157 // static
158 bool TextInputTestHelper::ConvertRectFromString(const std::string& str, 158 bool TextInputTestHelper::ConvertRectFromString(const std::string& str,
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
194 mouse_event.y = rect.CenterPoint().y(); 194 mouse_event.y = rect.CenterPoint().y();
195 mouse_event.clickCount = 1; 195 mouse_event.clickCount = 1;
196 tab->GetRenderViewHost()->ForwardMouseEvent(mouse_event); 196 tab->GetRenderViewHost()->ForwardMouseEvent(mouse_event);
197 197
198 mouse_event.type = blink::WebInputEvent::MouseUp; 198 mouse_event.type = blink::WebInputEvent::MouseUp;
199 tab->GetRenderViewHost()->ForwardMouseEvent(mouse_event); 199 tab->GetRenderViewHost()->ForwardMouseEvent(mouse_event);
200 return true; 200 return true;
201 } 201 }
202 202
203 } // namespace chromeos 203 } // namespace chromeos
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698