Delete unused downloads page asset.
[chromium-blink-merge.git] / ppapi / proxy / ppp_printing_proxy.h
blob03bebf7b6aac9294457f3f77297041e98806844e
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef PPAPI_PROXY_PPP_PRINTING_PROXY_H_
6 #define PPAPI_PROXY_PPP_PRINTING_PROXY_H_
8 #include <string>
9 #include <vector>
11 #include "ppapi/c/dev/ppp_printing_dev.h"
12 #include "ppapi/proxy/interface_proxy.h"
14 struct PP_PrintPageNumberRange_Dev;
16 namespace ppapi {
18 class HostResource;
20 namespace proxy {
22 class PPP_Printing_Proxy : public InterfaceProxy {
23 public:
24 PPP_Printing_Proxy(Dispatcher* dispatcher);
25 virtual ~PPP_Printing_Proxy();
27 static const PPP_Printing_Dev* GetProxyInterface();
29 // InterfaceProxy implementation.
30 virtual bool OnMessageReceived(const IPC::Message& msg);
32 private:
33 // Message handlers.
34 void OnPluginMsgQuerySupportedFormats(PP_Instance instance, uint32_t* result);
35 void OnPluginMsgBegin(PP_Instance instance,
36 const std::string& settings_string,
37 int32_t* result);
38 void OnPluginMsgPrintPages(
39 PP_Instance instance,
40 const std::vector<PP_PrintPageNumberRange_Dev>& pages,
41 HostResource* result);
42 void OnPluginMsgEnd(PP_Instance instance);
43 void OnPluginMsgIsScalingDisabled(PP_Instance instance, bool* result);
45 // When this proxy is in the plugin side, this value caches the interface
46 // pointer so we don't have to retrieve it from the dispatcher each time.
47 // In the host, this value is always NULL.
48 const PPP_Printing_Dev* ppp_printing_impl_;
50 DISALLOW_COPY_AND_ASSIGN(PPP_Printing_Proxy);
53 } // namespace proxy
54 } // namespace ppapi
56 #endif // PPAPI_PROXY_PPP_PRINTING_PROXY_H_