Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(64)

Side by Side Diff: ppapi/proxy/ppb_buffer_proxy.cc

Issue 7149026: Implement flash menu and net connector resources using the API/thunk model. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 9 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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 #include "ppapi/proxy/ppb_buffer_proxy.h" 5 #include "ppapi/proxy/ppb_buffer_proxy.h"
6 6
7 #include <vector> 7 #include <vector>
8 8
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "build/build_config.h" 10 #include "build/build_config.h"
(...skipping 26 matching lines...) Expand all
37 public PluginResource { 37 public PluginResource {
38 public: 38 public:
39 Buffer(const HostResource& resource, 39 Buffer(const HostResource& resource,
40 const base::SharedMemoryHandle& shm_handle, 40 const base::SharedMemoryHandle& shm_handle,
41 uint32_t size); 41 uint32_t size);
42 virtual ~Buffer(); 42 virtual ~Buffer();
43 43
44 // Resource overrides. 44 // Resource overrides.
45 virtual Buffer* AsBuffer() OVERRIDE; 45 virtual Buffer* AsBuffer() OVERRIDE;
46 46
47 // ResourceObjectBase overries. 47 // ResourceObjectBase overrides.
48 virtual ppapi::thunk::PPB_Buffer_API* AsPPB_Buffer_API() OVERRIDE; 48 virtual ppapi::thunk::PPB_Buffer_API* AsPPB_Buffer_API() OVERRIDE;
49 49
50 // PPB_Buffer_API implementation. 50 // PPB_Buffer_API implementation.
51 virtual PP_Bool Describe(uint32_t* size_in_bytes) OVERRIDE; 51 virtual PP_Bool Describe(uint32_t* size_in_bytes) OVERRIDE;
52 virtual PP_Bool IsMapped() OVERRIDE; 52 virtual PP_Bool IsMapped() OVERRIDE;
53 virtual void* Map() OVERRIDE; 53 virtual void* Map() OVERRIDE;
54 virtual void Unmap() OVERRIDE; 54 virtual void Unmap() OVERRIDE;
55 55
56 private: 56 private:
57 base::SharedMemory shm_; 57 base::SharedMemory shm_;
(...skipping 124 matching lines...) Expand 10 before | Expand all | Expand 10 after
182 #elif defined(OS_POSIX) 182 #elif defined(OS_POSIX)
183 local_fd; 183 local_fd;
184 #else 184 #else
185 #error Not implemented. 185 #error Not implemented.
186 #endif 186 #endif
187 *result_shm_handle = dispatcher->ShareHandleWithRemote(platform_file, false); 187 *result_shm_handle = dispatcher->ShareHandleWithRemote(platform_file, false);
188 } 188 }
189 189
190 } // namespace proxy 190 } // namespace proxy
191 } // namespace pp 191 } // namespace pp
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698