OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef NATIVE_CLIENT_SRC_SHARED_PPAPI_PROXY_PLUGIN_GRAPHICS_2D_H_ | 5 #ifndef NATIVE_CLIENT_SRC_SHARED_PPAPI_PROXY_PLUGIN_GRAPHICS_2D_H_ |
6 #define NATIVE_CLIENT_SRC_SHARED_PPAPI_PROXY_PLUGIN_GRAPHICS_2D_H_ | 6 #define NATIVE_CLIENT_SRC_SHARED_PPAPI_PROXY_PLUGIN_GRAPHICS_2D_H_ |
7 | 7 |
8 #include "native_client/src/include/nacl_macros.h" | 8 #include "native_client/src/include/nacl_macros.h" |
9 #include "native_client/src/shared/ppapi_proxy/plugin_resource.h" | 9 #include "native_client/src/shared/ppapi_proxy/plugin_resource.h" |
10 #include "ppapi/c/ppb_graphics_2d.h" | 10 #include "ppapi/c/ppb_graphics_2d.h" |
11 | 11 |
12 namespace ppapi_proxy { | 12 namespace ppapi_proxy { |
13 | 13 |
14 // Implements the untrusted side of the PPB_Graphics2D interface. | 14 // Implements the untrusted side of the PPB_Graphics2D interface. |
15 class PluginGraphics2D : public PluginResource { | 15 class PluginGraphics2D : public PluginResource { |
16 public: | 16 public: |
17 PluginGraphics2D() {} | 17 PluginGraphics2D() {} |
18 bool InitFromBrowserResource(PP_Resource resource) { return true; } | 18 bool InitFromBrowserResource(PP_Resource resource) { return true; } |
19 | 19 |
20 static const PPB_Graphics2D* GetInterface(); | 20 static const PPB_Graphics2D* GetInterface(); |
21 | 21 |
| 22 protected: |
| 23 virtual ~PluginGraphics2D() {} |
| 24 |
22 private: | 25 private: |
23 IMPLEMENT_RESOURCE(PluginGraphics2D); | 26 IMPLEMENT_RESOURCE(PluginGraphics2D); |
24 NACL_DISALLOW_COPY_AND_ASSIGN(PluginGraphics2D); | 27 NACL_DISALLOW_COPY_AND_ASSIGN(PluginGraphics2D); |
25 }; | 28 }; |
26 | 29 |
27 } // namespace ppapi_proxy | 30 } // namespace ppapi_proxy |
28 | 31 |
29 #endif // NATIVE_CLIENT_SRC_SHARED_PPAPI_PROXY_PLUGIN_GRAPHICS_2D_H_ | 32 #endif // NATIVE_CLIENT_SRC_SHARED_PPAPI_PROXY_PLUGIN_GRAPHICS_2D_H_ |
OLD | NEW |