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

Side by Side Diff: cc/layers/surface_layer.h

Issue 1866203004: Convert //cc from scoped_ptr to std::unique_ptr. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: scopedptrcc: rebase Created 4 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 unified diff | Download patch
« no previous file with comments | « cc/layers/solid_color_scrollbar_layer_impl.cc ('k') | cc/layers/surface_layer.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CC_LAYERS_SURFACE_LAYER_H_ 5 #ifndef CC_LAYERS_SURFACE_LAYER_H_
6 #define CC_LAYERS_SURFACE_LAYER_H_ 6 #define CC_LAYERS_SURFACE_LAYER_H_
7 7
8 #include "base/macros.h" 8 #include "base/macros.h"
9 #include "cc/base/cc_export.h" 9 #include "cc/base/cc_export.h"
10 #include "cc/layers/layer.h" 10 #include "cc/layers/layer.h"
(...skipping 16 matching lines...) Expand all
27 // received before a SurfaceId is destroyed. 27 // received before a SurfaceId is destroyed.
28 using RequireCallback = base::Callback<void(SurfaceId, SurfaceSequence)>; 28 using RequireCallback = base::Callback<void(SurfaceId, SurfaceSequence)>;
29 29
30 static scoped_refptr<SurfaceLayer> Create( 30 static scoped_refptr<SurfaceLayer> Create(
31 const SatisfyCallback& satisfy_callback, 31 const SatisfyCallback& satisfy_callback,
32 const RequireCallback& require_callback); 32 const RequireCallback& require_callback);
33 33
34 void SetSurfaceId(SurfaceId surface_id, float scale, const gfx::Size& size); 34 void SetSurfaceId(SurfaceId surface_id, float scale, const gfx::Size& size);
35 35
36 // Layer overrides. 36 // Layer overrides.
37 scoped_ptr<LayerImpl> CreateLayerImpl(LayerTreeImpl* tree_impl) override; 37 std::unique_ptr<LayerImpl> CreateLayerImpl(LayerTreeImpl* tree_impl) override;
38 void SetLayerTreeHost(LayerTreeHost* host) override; 38 void SetLayerTreeHost(LayerTreeHost* host) override;
39 void PushPropertiesTo(LayerImpl* layer) override; 39 void PushPropertiesTo(LayerImpl* layer) override;
40 40
41 protected: 41 protected:
42 SurfaceLayer(const SatisfyCallback& satisfy_callback, 42 SurfaceLayer(const SatisfyCallback& satisfy_callback,
43 const RequireCallback& require_callback); 43 const RequireCallback& require_callback);
44 bool HasDrawableContent() const override; 44 bool HasDrawableContent() const override;
45 45
46 private: 46 private:
47 ~SurfaceLayer() override; 47 ~SurfaceLayer() override;
48 void CreateNewDestroySequence(); 48 void CreateNewDestroySequence();
49 void SatisfyDestroySequence(); 49 void SatisfyDestroySequence();
50 50
51 SurfaceId surface_id_; 51 SurfaceId surface_id_;
52 gfx::Size surface_size_; 52 gfx::Size surface_size_;
53 float surface_scale_; 53 float surface_scale_;
54 SurfaceSequence destroy_sequence_; 54 SurfaceSequence destroy_sequence_;
55 SatisfyCallback satisfy_callback_; 55 SatisfyCallback satisfy_callback_;
56 RequireCallback require_callback_; 56 RequireCallback require_callback_;
57 57
58 DISALLOW_COPY_AND_ASSIGN(SurfaceLayer); 58 DISALLOW_COPY_AND_ASSIGN(SurfaceLayer);
59 }; 59 };
60 60
61 } // namespace cc 61 } // namespace cc
62 62
63 #endif // CC_LAYERS_SURFACE_LAYER_H_ 63 #endif // CC_LAYERS_SURFACE_LAYER_H_
OLDNEW
« no previous file with comments | « cc/layers/solid_color_scrollbar_layer_impl.cc ('k') | cc/layers/surface_layer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698