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

Side by Side Diff: content/browser/renderer_host/shared_memory_allocator_impl.h

Issue 2488913003: Replacing allocate bitmap IPC messages with a new Mojo interface. (Closed)
Patch Set: Clean-up Created 4 years, 1 month 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
OLDNEW
(Empty)
1 // Copyright 2016 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.
4
5 #ifndef CONTENT_BROWSER_RENDER_HOST_SHARED_MEMORY_ALLOCATOR_H_
6 #define CONTENT_BROWSER_RENDER_HOST_SHARED_MEMORY_ALLOCATOR_H_
7
8 #include "base/macros.h"
9 #include "base/memory/shared_memory.h"
10 #include "content/common/host_shared_bitmap_manager.h"
11 #include "content/common/shared_memory_allocator.mojom.h"
12 #include "mojo/public/cpp/bindings/interface_request.h"
13
14 namespace content {
15
16 class SharedMemoryAllocatorImpl : public mojom::SharedMemoryAllocator {
17 public:
18 static void Create(mojom::SharedMemoryAllocatorRequest request);
19
20 ~SharedMemoryAllocatorImpl() override;
21
22 private:
23 SharedMemoryAllocatorImpl();
24
25 // mojom::SharedMemoryAllocator implementation:
26 void AllocatedSharedBitmap(mojo::ScopedSharedBufferHandle buffer,
27 const gpu::Mailbox& id) override;
28 void DeletedSharedBitmap(const gpu::Mailbox& id) override;
29
30 HostSharedBitmapManagerClient bitmap_manager_client_;
31 base::ThreadChecker thread_checker_;
32
33 DISALLOW_COPY_AND_ASSIGN(SharedMemoryAllocatorImpl);
34 };
35
36 } // namespace content
37
38 #endif // CONTENT_BROWSER_RENDER_HOST_SHARED_MEMORY_ALLOCATOR_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698