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

Unified Diff: chrome/test/automation/tab_proxy.cc

Issue 3117017: Remove deprecated wstring Get(As)String() methods from Value, etc. (Closed)
Patch Set: fix win Created 10 years, 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/service/cloud_print/printer_job_handler.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/test/automation/tab_proxy.cc
diff --git a/chrome/test/automation/tab_proxy.cc b/chrome/test/automation/tab_proxy.cc
index 15d00d0c812d1926f3fc9760a4c6cfb78a98006e..cf37561b3b23164376e6f8de91521303fedc8d0c 100644
--- a/chrome/test/automation/tab_proxy.cc
+++ b/chrome/test/automation/tab_proxy.cc
@@ -7,6 +7,7 @@
#include <algorithm>
#include "base/logging.h"
+#include "base/string16.h"
#include "base/utf_string_conversions.h"
#include "chrome/common/json_value_serializer.h"
#include "chrome/test/automation/automation_constants.h"
@@ -256,14 +257,15 @@ bool TabProxy::ExecuteAndExtractString(const std::wstring& frame_xpath,
if (!succeeded)
return false;
- std::wstring read_value;
DCHECK(root->IsType(Value::TYPE_LIST));
Value* value = NULL;
succeeded = static_cast<ListValue*>(root)->Get(0, &value);
if (succeeded) {
+ string16 read_value;
succeeded = value->GetAsString(&read_value);
if (succeeded) {
- string_value->swap(read_value);
+ // TODO(viettrungluu): remove conversion. (But should |jscript| be UTF-8?)
+ *string_value = UTF16ToWideHack(read_value);
}
}
« no previous file with comments | « chrome/service/cloud_print/printer_job_handler.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698