| Index: content/browser/renderer_host/pepper/pepper_filesystem_provider_host.h
|
| diff --git a/content/browser/renderer_host/pepper/pepper_filesystem_provider_host.h b/content/browser/renderer_host/pepper/pepper_filesystem_provider_host.h
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..da21a06c2e2a8f8b05addc34e655f837bb930a58
|
| --- /dev/null
|
| +++ b/content/browser/renderer_host/pepper/pepper_filesystem_provider_host.h
|
| @@ -0,0 +1,59 @@
|
| +// Copyright 2015 The Chromium Authors. All rights reserved.
|
| +// Use of this source code is governed by a BSD-style license that can be
|
| +// found in the LICENSE file.
|
| +
|
| +#ifndef PEPPERFILESYSTEMPROVIDERHOST_H
|
| +#define PEPPERFILESYSTEMPROVIDERHOST_H
|
| +
|
| +#include "ppapi/host/host_message_context.h"
|
| +#include "ppapi/host/resource_host.h"
|
| +
|
| +namespace content {
|
| +
|
| +class PepperFilesystemProviderBackend {
|
| +public:
|
| + virtual ~PepperFilesystemProviderBackend();
|
| + // Messages that interface with the provided filesystem backend
|
| + virtual int32_t SendMountRequest(
|
| + ppapi::host::HostMessageContext *context,
|
| + const base::ListValue&)=0;
|
| + virtual int32_t SendUnmountRequest(
|
| + ppapi::host::HostMessageContext* context,
|
| + std::string )=0;
|
| + virtual int32_t OnPluginResponse(
|
| + ppapi::host::HostMessageContext* context,
|
| + const base::ListValue&)=0;
|
| + virtual int32_t OnPluginWriteAck(
|
| + ppapi::host::HostMessageContext* context)=0;
|
| +};
|
| +
|
| +
|
| +class BrowserPpapiHost;
|
| +
|
| +class PepperFilesystemProviderHost :
|
| + public ppapi::host::ResourceHost
|
| +{
|
| +public:
|
| + PepperFilesystemProviderHost( BrowserPpapiHost *host,
|
| + PP_Instance instance,
|
| + PP_Resource resource);
|
| + ~PepperFilesystemProviderHost()override;
|
| +private:
|
| + scoped_ptr<PepperFilesystemProviderBackend> backend_;
|
| +
|
| + // ResourceMessageHandler interface
|
| +protected:
|
| + int32_t OnResourceMessageReceived(
|
| + const IPC::Message& msg, ppapi::host::HostMessageContext*context)override;
|
| + // Messages that interface with the provided filesystem backend
|
| + int32_t OnHostMsgMount(ppapi::host::HostMessageContext *context,
|
| + const base::ListValue&);
|
| + int32_t OnHostMsgUnmount(ppapi::host::HostMessageContext* context,
|
| + std::string );
|
| + int32_t OnHostMsgPluginResponse( ppapi::host::HostMessageContext* context,
|
| + const base::ListValue& );
|
| + int32_t OnHostMsgPluginWriteAck(ppapi::host::HostMessageContext* context);
|
| +};
|
| +} // namespace content
|
| +
|
| +#endif // PEPPERFILESYSTEMPROVIDERHOST_H
|
|
|