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

Unified Diff: cc/layers/surface_layer.h

Issue 1057283003: Remove parts of //cc we aren't using (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 5 years, 9 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
« no previous file with comments | « cc/layers/solid_color_scrollbar_layer_impl_unittest.cc ('k') | cc/layers/surface_layer.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/layers/surface_layer.h
diff --git a/cc/layers/surface_layer.h b/cc/layers/surface_layer.h
deleted file mode 100644
index 381369f5c615457831b7ae8014352d68e916bd3a..0000000000000000000000000000000000000000
--- a/cc/layers/surface_layer.h
+++ /dev/null
@@ -1,66 +0,0 @@
-// Copyright 2014 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.
-
-#ifndef CC_LAYERS_SURFACE_LAYER_H_
-#define CC_LAYERS_SURFACE_LAYER_H_
-
-#include "cc/base/cc_export.h"
-#include "cc/layers/layer.h"
-#include "cc/surfaces/surface_id.h"
-#include "cc/surfaces/surface_sequence.h"
-#include "ui/gfx/geometry/size.h"
-
-namespace cc {
-
-// A layer that renders a surface referencing the output of another compositor
-// instance or client.
-class CC_EXPORT SurfaceLayer : public Layer {
- public:
- // This callback is run when a SurfaceSequence needs to be satisfied, but
- // the parent compositor is unable to. It can be called on either the main
- // or impl threads.
- using SatisfyCallback = base::Callback<void(SurfaceSequence)>;
-
- // This callback is run to require that a specific SurfaceSequence is
- // received before a SurfaceId is destroyed.
- using RequireCallback = base::Callback<void(SurfaceId, SurfaceSequence)>;
-
- static scoped_refptr<SurfaceLayer> Create(
- const SatisfyCallback& satisfy_callback,
- const RequireCallback& require_callback);
-
- void SetSurfaceId(SurfaceId surface_id, float scale, const gfx::Size& size);
-
- // Layer overrides.
- scoped_ptr<LayerImpl> CreateLayerImpl(LayerTreeImpl* tree_impl) override;
- void SetLayerTreeHost(LayerTreeHost* host) override;
- void PushPropertiesTo(LayerImpl* layer) override;
- void CalculateContentsScale(float ideal_contents_scale,
- float* contents_scale_x,
- float* contents_scale_y,
- gfx::Size* content_bounds) override;
-
- protected:
- SurfaceLayer(const SatisfyCallback& satisfy_callback,
- const RequireCallback& require_callback);
- bool HasDrawableContent() const override;
-
- private:
- ~SurfaceLayer() override;
- void CreateNewDestroySequence();
- void SatisfyDestroySequence();
-
- SurfaceId surface_id_;
- gfx::Size surface_size_;
- float surface_scale_;
- SurfaceSequence destroy_sequence_;
- SatisfyCallback satisfy_callback_;
- RequireCallback require_callback_;
-
- DISALLOW_COPY_AND_ASSIGN(SurfaceLayer);
-};
-
-} // namespace cc
-
-#endif // CC_LAYERS_SURFACE_LAYER_H_
« no previous file with comments | « cc/layers/solid_color_scrollbar_layer_impl_unittest.cc ('k') | cc/layers/surface_layer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698