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

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

Issue 10534045: Add CreateTemporaryFile to PPB_Flash_File_ModuleLocal. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 6 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/renderer/pepper/pepper_plugin_delegate_impl.cc
diff --git a/content/renderer/pepper/pepper_plugin_delegate_impl.cc b/content/renderer/pepper/pepper_plugin_delegate_impl.cc
index 0a30831cb9579dad251ccd12617d4eeee39d67bd..800920deaf55cca9007d6e158910af6f1f0194ab 100644
--- a/content/renderer/pepper/pepper_plugin_delegate_impl.cc
+++ b/content/renderer/pepper/pepper_plugin_delegate_impl.cc
@@ -978,6 +978,23 @@ base::PlatformFileError PepperPluginDelegateImpl::GetDirContents(
return error;
}
+base::PlatformFileError PepperPluginDelegateImpl::CreateTemporaryFile(
+ const ppapi::PepperFilePath& dir_path,
+ base::PlatformFile* file,
+ std::string* file_name) {
+ IPC::PlatformFileForTransit transit_file;
+ base::PlatformFileError error;
+ IPC::Message* msg = new PepperFileMsg_CreateTemporaryFile(
+ dir_path, &error, &transit_file, file_name);
+ if (!render_view_->Send(msg)) {
+ *file = base::kInvalidPlatformFileValue;
+ file_name->clear();
+ return base::PLATFORM_FILE_ERROR_FAILED;
+ }
+ *file = IPC::PlatformFileForTransitToPlatformFile(transit_file);
+ return error;
+}
+
void PepperPluginDelegateImpl::SyncGetFileSystemPlatformPath(
const GURL& url, FilePath* platform_path) {
RenderThreadImpl::current()->Send(new FileSystemHostMsg_SyncGetPlatformPath(

Powered by Google App Engine
This is Rietveld 408576698