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

Side by Side Diff: content/renderer/pepper/ppb_buffer_impl.cc

Issue 384793003: PPAPI: Remove content/renderer/pepper/common.h (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 5 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) 2012 The Chromium Authors. All rights reserved. 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 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 "content/renderer/pepper/ppb_buffer_impl.h" 5 #include "content/renderer/pepper/ppb_buffer_impl.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 8
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/memory/scoped_ptr.h" 10 #include "base/memory/scoped_ptr.h"
11 #include "content/renderer/pepper/common.h"
12 #include "content/renderer/render_thread_impl.h" 11 #include "content/renderer/render_thread_impl.h"
13 #include "ppapi/c/dev/ppb_buffer_dev.h" 12 #include "ppapi/c/dev/ppb_buffer_dev.h"
13 #include "ppapi/c/pp_bool.h"
14 #include "ppapi/c/pp_errors.h" 14 #include "ppapi/c/pp_errors.h"
15 #include "ppapi/c/pp_instance.h" 15 #include "ppapi/c/pp_instance.h"
16 #include "ppapi/c/pp_resource.h" 16 #include "ppapi/c/pp_resource.h"
17 17
18 using ppapi::thunk::PPB_Buffer_API; 18 using ppapi::thunk::PPB_Buffer_API;
19 19
20 namespace content { 20 namespace content {
21 21
22 PPB_Buffer_Impl::PPB_Buffer_Impl(PP_Instance instance) 22 PPB_Buffer_Impl::PPB_Buffer_Impl(PP_Instance instance)
23 : Resource(ppapi::OBJECT_IS_IMPL, instance), size_(0), map_count_(0) {} 23 : Resource(ppapi::OBJECT_IS_IMPL, instance), size_(0), map_count_(0) {}
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after
93 data_ = api->Map(); 93 data_ = api->Map();
94 api->Describe(&size_); 94 api->Describe(&size_);
95 } 95 }
96 96
97 BufferAutoMapper::~BufferAutoMapper() { 97 BufferAutoMapper::~BufferAutoMapper() {
98 if (needs_unmap_) 98 if (needs_unmap_)
99 api_->Unmap(); 99 api_->Unmap();
100 } 100 }
101 101
102 } // namespace content 102 } // namespace content
OLDNEW
« no previous file with comments | « content/renderer/pepper/ppb_broker_impl.cc ('k') | content/renderer/pepper/ppb_image_data_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698