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

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

Issue 2328463004: Implement WebGL's commit on the main thread (Closed)
Patch Set: fix compile error on win_dbg Created 4 years, 3 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/offscreen_canvas_frame_receiver_impl.cc
diff --git a/content/browser/renderer_host/offscreen_canvas_frame_receiver_impl.cc b/content/browser/renderer_host/offscreen_canvas_frame_receiver_impl.cc
deleted file mode 100644
index 3496764baec403ba23da29e3d3fff80ec13343b2..0000000000000000000000000000000000000000
--- a/content/browser/renderer_host/offscreen_canvas_frame_receiver_impl.cc
+++ /dev/null
@@ -1,65 +0,0 @@
-// Copyright 2016 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#include "content/browser/renderer_host/offscreen_canvas_frame_receiver_impl.h"
-
-#include "cc/surfaces/surface.h"
-#include "cc/surfaces/surface_manager.h"
-#include "content/browser/compositor/surface_utils.h"
-#include "mojo/public/cpp/bindings/strong_binding.h"
-
-namespace content {
-
-OffscreenCanvasFrameReceiverImpl::OffscreenCanvasFrameReceiverImpl() {}
-
-OffscreenCanvasFrameReceiverImpl::~OffscreenCanvasFrameReceiverImpl() {
- if (surface_factory_) {
- if (!GetSurfaceManager()) {
- // Inform SurfaceFactory that SurfaceManager's no longer alive to
- // avoid its destruction error.
- surface_factory_->DidDestroySurfaceManager();
- } else {
- GetSurfaceManager()->InvalidateSurfaceClientId(surface_id_.client_id());
- }
- surface_factory_->Destroy(surface_id_);
- }
-}
-
-// static
-void OffscreenCanvasFrameReceiverImpl::Create(
- blink::mojom::OffscreenCanvasFrameReceiverRequest request) {
- mojo::MakeStrongBinding(base::MakeUnique<OffscreenCanvasFrameReceiverImpl>(),
- std::move(request));
-}
-
-void OffscreenCanvasFrameReceiverImpl::SubmitCompositorFrame(
- const cc::SurfaceId& surface_id,
- cc::CompositorFrame frame) {
- if (!surface_factory_) {
- cc::SurfaceManager* manager = GetSurfaceManager();
- surface_factory_ = base::MakeUnique<cc::SurfaceFactory>(manager, this);
- surface_factory_->Create(surface_id);
-
- GetSurfaceManager()->RegisterSurfaceClientId(surface_id.client_id());
- }
- if (surface_id_.is_null()) {
- surface_id_ = surface_id;
- }
- surface_factory_->SubmitCompositorFrame(surface_id, std::move(frame),
- base::Closure());
-}
-
-// TODO(619136): Implement cc::SurfaceFactoryClient functions for resources
-// return.
-void OffscreenCanvasFrameReceiverImpl::ReturnResources(
- const cc::ReturnedResourceArray& resources) {}
-
-void OffscreenCanvasFrameReceiverImpl::WillDrawSurface(
- const cc::SurfaceId& id,
- const gfx::Rect& damage_rect) {}
-
-void OffscreenCanvasFrameReceiverImpl::SetBeginFrameSource(
- cc::BeginFrameSource* begin_frame_source) {}
-
-} // namespace content

Powered by Google App Engine
This is Rietveld 408576698