Index: content/renderer/pepper/ppb_file_ref_impl.cc |
=================================================================== |
--- content/renderer/pepper/ppb_file_ref_impl.cc (revision 214423) |
+++ content/renderer/pepper/ppb_file_ref_impl.cc (working copy) |
@@ -12,10 +12,8 @@ |
#include "content/renderer/pepper/common.h" |
#include "content/renderer/pepper/pepper_file_system_host.h" |
#include "content/renderer/pepper/pepper_helper_impl.h" |
-#include "content/renderer/pepper/pepper_plugin_instance_impl.h" |
#include "content/renderer/pepper/plugin_module.h" |
#include "content/renderer/pepper/renderer_ppapi_host_impl.h" |
-#include "content/renderer/pepper/resource_helper.h" |
#include "content/renderer/render_thread_impl.h" |
#include "net/base/escape.h" |
#include "ppapi/c/pp_errors.h" |
@@ -236,11 +234,6 @@ |
PPB_FileRef_Impl* PPB_FileRef_Impl::CreateInternal(PP_Instance instance, |
PP_Resource pp_file_system, |
const std::string& path) { |
- PepperPluginInstanceImpl* plugin_instance = |
- ResourceHelper::PPInstanceToPluginInstance(instance); |
- if (!plugin_instance || !plugin_instance->helper()) |
- return 0; |
- |
ppapi::host::ResourceHost* host = GetResourceHostInternal( |
instance, pp_file_system); |
if (!host) |
@@ -454,11 +447,6 @@ |
int32_t PPB_FileRef_Impl::QueryInHost( |
linked_ptr<PP_FileInfo> info, |
scoped_refptr<TrackedCallback> callback) { |
- scoped_refptr<PepperPluginInstanceImpl> plugin_instance = |
- ResourceHelper::GetPluginInstance(this); |
- if (!plugin_instance.get()) |
- return PP_ERROR_FAILED; |
- |
if (!file_system_) { |
// External file system |
// We have to do something totally different for external file systems. |
@@ -466,11 +454,10 @@ |
// TODO(teravest): Use the SequencedWorkerPool instead. |
scoped_refptr<base::TaskRunner> task_runner = |
RenderThreadImpl::current()->GetFileThreadMessageLoopProxy(); |
- if (!plugin_instance->helper()->AsyncOpenFile( |
- GetSystemPath(), |
- base::PLATFORM_FILE_OPEN | base::PLATFORM_FILE_READ, |
- base::Bind(&QueryCallback, task_runner, info, callback))) |
- return PP_ERROR_FAILED; |
+ RenderThreadImpl::current()->AsyncOpenFile( |
+ GetSystemPath(), |
+ base::PLATFORM_FILE_OPEN | base::PLATFORM_FILE_READ, |
+ base::Bind(&QueryCallback, task_runner, info, callback)); |
} else { |
// Non-external file system |
if (!HasValidFileSystem()) |