summaryrefslogtreecommitdiffstats
path: root/content/renderer
diff options
context:
space:
mode:
authoryzshen@chromium.org <yzshen@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-06-15 22:56:53 +0000
committeryzshen@chromium.org <yzshen@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-06-15 22:56:53 +0000
commit481a4b7f34565ef087c8aa44c8e04f9f0e466b2d (patch)
tree58a27508ef38cecf35d478710ee9039aa9a2cea0 /content/renderer
parente5d5b0e8f45962bbb5cba1a6dd9a3b31eadb9429 (diff)
downloadchromium_src-481a4b7f34565ef087c8aa44c8e04f9f0e466b2d.zip
chromium_src-481a4b7f34565ef087c8aa44c8e04f9f0e466b2d.tar.gz
chromium_src-481a4b7f34565ef087c8aa44c8e04f9f0e466b2d.tar.bz2
Add CreateTemporaryFile to PPB_Flash_File_ModuleLocal.
BUG=129807 TEST=None Review URL: https://chromiumcodereview.appspot.com/10534045 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@142512 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'content/renderer')
-rw-r--r--content/renderer/pepper/pepper_plugin_delegate_impl.cc14
-rw-r--r--content/renderer/pepper/pepper_plugin_delegate_impl.h2
2 files changed, 16 insertions, 0 deletions
diff --git a/content/renderer/pepper/pepper_plugin_delegate_impl.cc b/content/renderer/pepper/pepper_plugin_delegate_impl.cc
index 0a30831..18c40a9 100644
--- a/content/renderer/pepper/pepper_plugin_delegate_impl.cc
+++ b/content/renderer/pepper/pepper_plugin_delegate_impl.cc
@@ -978,6 +978,20 @@ base::PlatformFileError PepperPluginDelegateImpl::GetDirContents(
return error;
}
+base::PlatformFileError PepperPluginDelegateImpl::CreateTemporaryFile(
+ base::PlatformFile* file) {
+ IPC::PlatformFileForTransit transit_file;
+ base::PlatformFileError error;
+ IPC::Message* msg = new PepperFileMsg_CreateTemporaryFile(&error,
+ &transit_file);
+ if (!render_view_->Send(msg)) {
+ *file = base::kInvalidPlatformFileValue;
+ 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(
diff --git a/content/renderer/pepper/pepper_plugin_delegate_impl.h b/content/renderer/pepper/pepper_plugin_delegate_impl.h
index c013402..9cae5fa 100644
--- a/content/renderer/pepper/pepper_plugin_delegate_impl.h
+++ b/content/renderer/pepper/pepper_plugin_delegate_impl.h
@@ -268,6 +268,8 @@ class PepperPluginDelegateImpl
virtual base::PlatformFileError GetDirContents(
const ppapi::PepperFilePath& path,
ppapi::DirContents* contents) OVERRIDE;
+ virtual base::PlatformFileError CreateTemporaryFile(
+ base::PlatformFile* file) OVERRIDE;
virtual void SyncGetFileSystemPlatformPath(
const GURL& url,
FilePath* platform_path) OVERRIDE;