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

Side by Side Diff: chrome/test/automation/tab_proxy.cc

Issue 94013004: Add base:: to string16s in chrome/. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: try again 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
« no previous file with comments | « chrome/service/service_process.cc ('k') | chrome/test/base/browser_with_test_window_test.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) 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 "chrome/test/automation/tab_proxy.h" 5 #include "chrome/test/automation/tab_proxy.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 8
9 #include "base/json/json_string_value_serializer.h" 9 #include "base/json/json_string_value_serializer.h"
10 #include "base/logging.h" 10 #include "base/logging.h"
(...skipping 159 matching lines...) Expand 10 before | Expand all | Expand 10 after
170 const std::wstring& jscript, 170 const std::wstring& jscript,
171 std::wstring* string_value) { 171 std::wstring* string_value) {
172 scoped_ptr<Value> root(ExecuteAndExtractValue(frame_xpath, jscript)); 172 scoped_ptr<Value> root(ExecuteAndExtractValue(frame_xpath, jscript));
173 if (root == NULL) 173 if (root == NULL)
174 return false; 174 return false;
175 175
176 DCHECK(root->IsType(Value::TYPE_LIST)); 176 DCHECK(root->IsType(Value::TYPE_LIST));
177 Value* value = NULL; 177 Value* value = NULL;
178 bool succeeded = static_cast<ListValue*>(root.get())->Get(0, &value); 178 bool succeeded = static_cast<ListValue*>(root.get())->Get(0, &value);
179 if (succeeded) { 179 if (succeeded) {
180 string16 read_value; 180 base::string16 read_value;
181 succeeded = value->GetAsString(&read_value); 181 succeeded = value->GetAsString(&read_value);
182 if (succeeded) { 182 if (succeeded) {
183 // TODO(viettrungluu): remove conversion. (But should |jscript| be UTF-8?) 183 // TODO(viettrungluu): remove conversion. (But should |jscript| be UTF-8?)
184 *string_value = UTF16ToWideHack(read_value); 184 *string_value = UTF16ToWideHack(read_value);
185 } 185 }
186 } 186 }
187 return succeeded; 187 return succeeded;
188 } 188 }
189 189
190 bool TabProxy::ExecuteAndExtractBool(const std::wstring& frame_xpath, 190 bool TabProxy::ExecuteAndExtractBool(const std::wstring& frame_xpath,
(...skipping 173 matching lines...) Expand 10 before | Expand all | Expand 10 after
364 364
365 TabProxy::~TabProxy() {} 365 TabProxy::~TabProxy() {}
366 366
367 void TabProxy::FirstObjectAdded() { 367 void TabProxy::FirstObjectAdded() {
368 AddRef(); 368 AddRef();
369 } 369 }
370 370
371 void TabProxy::LastObjectRemoved() { 371 void TabProxy::LastObjectRemoved() {
372 Release(); 372 Release();
373 } 373 }
OLDNEW
« no previous file with comments | « chrome/service/service_process.cc ('k') | chrome/test/base/browser_with_test_window_test.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698