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

Unified Diff: content/child/child_shared_bitmap_manager.h

Issue 2549213005: Reland of placing allocate bitmap IPC messages with a new Mojo interface. (Closed)
Patch Set: Created 4 years 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 side-by-side diff with in-line comments
Download patch
Index: content/child/child_shared_bitmap_manager.h
diff --git a/content/child/child_shared_bitmap_manager.h b/content/child/child_shared_bitmap_manager.h
index feb065bb92a433fb64f549e3c5fd10d27e3ba37e..b63d3e50a11493b73aaa3455a5a1afefbb224aaa 100644
--- a/content/child/child_shared_bitmap_manager.h
+++ b/content/child/child_shared_bitmap_manager.h
@@ -13,7 +13,8 @@
#include "base/memory/ref_counted.h"
#include "base/memory/shared_memory.h"
#include "cc/resources/shared_bitmap_manager.h"
-#include "content/child/thread_safe_sender.h"
+#include "content/common/render_message_filter.mojom.h"
+#include "mojo/public/cpp/bindings/thread_safe_interface_ptr.h"
namespace content {
@@ -31,7 +32,9 @@
class ChildSharedBitmapManager : public cc::SharedBitmapManager {
public:
- ChildSharedBitmapManager(scoped_refptr<ThreadSafeSender> sender);
+ explicit ChildSharedBitmapManager(
+ const scoped_refptr<mojom::ThreadSafeRenderMessageFilterAssociatedPtr>&
+ render_message_filter_ptr);
~ChildSharedBitmapManager() override;
// cc::SharedBitmapManager implementation.
@@ -43,11 +46,13 @@
std::unique_ptr<cc::SharedBitmap> GetBitmapForSharedMemory(
base::SharedMemory* mem);
- std::unique_ptr<SharedMemoryBitmap> AllocateSharedMemoryBitmap(
- const gfx::Size& size);
private:
- scoped_refptr<ThreadSafeSender> sender_;
+ void NotifyAllocatedSharedBitmap(base::SharedMemory* memory,
+ const cc::SharedBitmapId& id);
+
+ scoped_refptr<mojom::ThreadSafeRenderMessageFilterAssociatedPtr>
+ render_message_filter_ptr_;
DISALLOW_COPY_AND_ASSIGN(ChildSharedBitmapManager);
};
« no previous file with comments | « content/browser/renderer_host/render_message_filter.cc ('k') | content/child/child_shared_bitmap_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698