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

Unified Diff: content/renderer/pepper/pepper_file_chooser_host.cc

Issue 637493002: Clean up ifdef around FilePath creation in /src/content (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixing build error Created 6 years, 2 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/pepper/pepper_file_chooser_host.cc
diff --git a/content/renderer/pepper/pepper_file_chooser_host.cc b/content/renderer/pepper/pepper_file_chooser_host.cc
index d067c201e39bab8a16cbf590796c2cb549671289..f0b0697f7d690fc40c27809423a75839e9d07b6e 100644
--- a/content/renderer/pepper/pepper_file_chooser_host.cc
+++ b/content/renderer/pepper/pepper_file_chooser_host.cc
@@ -94,11 +94,7 @@ void PepperFileChooserHost::StoreChosenFiles(
std::vector<base::FilePath> file_paths;
std::vector<std::string> display_names;
for (size_t i = 0; i < files.size(); i++) {
-#if defined(OS_WIN)
- base::FilePath file_path(base::UTF8ToWide(files[i].path));
-#else
- base::FilePath file_path(files[i].path);
-#endif
+ base::FilePath file_path = base::FilePath::FromUTF8Unsafe(files[i].path);
file_paths.push_back(file_path);
create_msgs.push_back(PpapiHostMsg_FileRef_CreateForRawFS(file_path));
display_names.push_back(files[i].display_name);
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698