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

Unified Diff: content/browser/renderer_host/render_message_filter.cc

Issue 2717213004: Move SharedBitmapManager implementation out of content/ (Closed)
Patch Set: rebase Created 3 years, 8 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 side-by-side diff with in-line comments
Download patch
Index: content/browser/renderer_host/render_message_filter.cc
diff --git a/content/browser/renderer_host/render_message_filter.cc b/content/browser/renderer_host/render_message_filter.cc
index e1359fbe57fe548ef0594726fd91f1ae84cd21b1..6276ca0fcaf9a2a39c09d8bd8fa34860c03c9013 100644
--- a/content/browser/renderer_host/render_message_filter.cc
+++ b/content/browser/renderer_host/render_message_filter.cc
@@ -135,7 +135,8 @@ RenderMessageFilter::RenderMessageFilter(
arraysize(kFilteredMessageClasses)),
BrowserAssociatedInterface<mojom::RenderMessageFilter>(this, this),
resource_dispatcher_host_(ResourceDispatcherHostImpl::Get()),
- bitmap_manager_client_(HostSharedBitmapManager::current()),
+ bitmap_manager_client_(
+ display_compositor::HostSharedBitmapManager::current()),
request_context_(request_context),
resource_context_(browser_context->GetResourceContext()),
render_widget_helper_(render_widget_helper),
@@ -260,6 +261,11 @@ void RenderMessageFilter::CreateFullscreenWidget(
callback.Run(route_id);
}
+void RenderMessageFilter::GetSharedBitmapManager(
+ cc::mojom::SharedBitmapManagerAssociatedRequest request) {
+ bitmap_manager_client_.Bind(std::move(request));
+}
+
#if defined(OS_MACOSX)
void RenderMessageFilter::OnLoadFont(const FontDescriptor& font,
@@ -290,21 +296,6 @@ void RenderMessageFilter::SendLoadFontReply(IPC::Message* reply,
#endif // defined(OS_MACOSX)
-void RenderMessageFilter::AllocatedSharedBitmap(
- mojo::ScopedSharedBufferHandle buffer,
- const cc::SharedBitmapId& id) {
- base::SharedMemoryHandle memory_handle;
- size_t size;
- MojoResult result = mojo::UnwrapSharedMemoryHandle(
- std::move(buffer), &memory_handle, &size, NULL);
- DCHECK_EQ(result, MOJO_RESULT_OK);
- bitmap_manager_client_.ChildAllocatedSharedBitmap(size, memory_handle, id);
-}
-
-void RenderMessageFilter::DeletedSharedBitmap(const cc::SharedBitmapId& id) {
- bitmap_manager_client_.ChildDeletedSharedBitmap(id);
-}
-
#if defined(OS_LINUX)
void RenderMessageFilter::SetThreadPriorityOnFileThread(
base::PlatformThreadId ns_tid,
« no previous file with comments | « content/browser/renderer_host/render_message_filter.h ('k') | content/browser/renderer_host/render_widget_host_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698