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 WEBKIT_PLUGINS_PPAPI_PPB_BUFFER_IMPL_H_ | 5 #ifndef CONTENT_RENDERER_PEPPER_PPB_BUFFER_IMPL_H_ |
6 #define WEBKIT_PLUGINS_PPAPI_PPB_BUFFER_IMPL_H_ | 6 #define CONTENT_RENDERER_PEPPER_PPB_BUFFER_IMPL_H_ |
7 | 7 |
8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
9 #include "base/memory/ref_counted.h" | 9 #include "base/memory/ref_counted.h" |
10 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
11 #include "base/memory/shared_memory.h" | 11 #include "base/memory/shared_memory.h" |
12 #include "ppapi/shared_impl/resource.h" | 12 #include "ppapi/shared_impl/resource.h" |
13 #include "ppapi/thunk/ppb_buffer_api.h" | 13 #include "ppapi/thunk/ppb_buffer_api.h" |
14 #include "webkit/plugins/webkit_plugins_export.h" | |
15 | 14 |
16 namespace webkit { | 15 namespace webkit { |
17 namespace ppapi { | 16 namespace ppapi { |
18 | 17 |
19 class WEBKIT_PLUGINS_EXPORT PPB_Buffer_Impl : | 18 class PPB_Buffer_Impl : |
20 public ::ppapi::Resource, | 19 public ::ppapi::Resource, |
21 public ::ppapi::thunk::PPB_Buffer_API { | 20 public ::ppapi::thunk::PPB_Buffer_API { |
22 public: | 21 public: |
23 virtual ~PPB_Buffer_Impl(); | 22 virtual ~PPB_Buffer_Impl(); |
24 | 23 |
25 static PP_Resource Create(PP_Instance instance, uint32_t size); | 24 static PP_Resource Create(PP_Instance instance, uint32_t size); |
26 static scoped_refptr<PPB_Buffer_Impl> CreateResource(PP_Instance instance, | 25 static scoped_refptr<PPB_Buffer_Impl> CreateResource(PP_Instance instance, |
27 uint32_t size); | 26 uint32_t size); |
28 | 27 |
29 virtual PPB_Buffer_Impl* AsPPB_Buffer_Impl(); | 28 virtual PPB_Buffer_Impl* AsPPB_Buffer_Impl(); |
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
72 | 71 |
73 void* data_; | 72 void* data_; |
74 uint32_t size_; | 73 uint32_t size_; |
75 | 74 |
76 DISALLOW_COPY_AND_ASSIGN(BufferAutoMapper); | 75 DISALLOW_COPY_AND_ASSIGN(BufferAutoMapper); |
77 }; | 76 }; |
78 | 77 |
79 } // namespace ppapi | 78 } // namespace ppapi |
80 } // namespace webkit | 79 } // namespace webkit |
81 | 80 |
82 #endif // WEBKIT_PLUGINS_PPAPI_PPB_BUFFER_IMPL_H_ | 81 #endif // CONTENT_RENDERER_PEPPER_PPB_BUFFER_IMPL_H_ |
OLD | NEW |