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

Unified Diff: content/shell/renderer/layout_test/blink_test_runner.cc

Issue 1686263008: Add utility method for WebString to base::FilePath conversion (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 10 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
Index: content/shell/renderer/layout_test/blink_test_runner.cc
diff --git a/content/shell/renderer/layout_test/blink_test_runner.cc b/content/shell/renderer/layout_test/blink_test_runner.cc
index 0a2bebaee559eb465a070021987fd8fc8c3f2052..cfcfcf215eb025e6f4a0dbe10fb993b1607d1a82 100644
--- a/content/shell/renderer/layout_test/blink_test_runner.cc
+++ b/content/shell/renderer/layout_test/blink_test_runner.cc
@@ -57,6 +57,7 @@
#include "net/base/filename_util.h"
#include "net/base/net_errors.h"
#include "skia/ext/platform_canvas.h"
+#include "third_party/WebKit/public/platform/FilePathConversion.h"
#include "third_party/WebKit/public/platform/Platform.h"
#include "third_party/WebKit/public/platform/WebCString.h"
#include "third_party/WebKit/public/platform/WebPoint.h"
@@ -327,7 +328,7 @@ WebString BlinkTestRunner::RegisterIsolatedFileSystem(
const blink::WebVector<blink::WebString>& absolute_filenames) {
std::vector<base::FilePath> files;
for (size_t i = 0; i < absolute_filenames.size(); ++i)
- files.push_back(base::FilePath::FromUTF16Unsafe(absolute_filenames[i]));
Nico 2016/02/15 16:45:14 Before: On Windows: One conversion from WebString
+ files.push_back(blink::WebStringToFilePath(absolute_filenames[i]));
std::string filesystem_id;
Send(new LayoutTestHostMsg_RegisterIsolatedFileSystem(
routing_id(), files, &filesystem_id));

Powered by Google App Engine
This is Rietveld 408576698