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

Side by Side Diff: cc/test/push_properties_counting_layer.h

Issue 2493523003: cc: Remove unused proto conversion code. (Closed)
Patch Set: test Created 4 years, 1 month 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/test/fake_remote_compositor_bridge.cc ('k') | cc/test/push_properties_counting_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 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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_TEST_PUSH_PROPERTIES_COUNTING_LAYER_H_ 5 #ifndef CC_TEST_PUSH_PROPERTIES_COUNTING_LAYER_H_
6 #define CC_TEST_PUSH_PROPERTIES_COUNTING_LAYER_H_ 6 #define CC_TEST_PUSH_PROPERTIES_COUNTING_LAYER_H_
7 7
8 #include <memory> 8 #include <memory>
9 9
10 #include "base/macros.h" 10 #include "base/macros.h"
11 #include "base/memory/ref_counted.h" 11 #include "base/memory/ref_counted.h"
12 #include "cc/layers/layer.h" 12 #include "cc/layers/layer.h"
13 #include "cc/proto/layer.pb.h" 13 #include "cc/proto/layer.pb.h"
14 14
15 namespace cc { 15 namespace cc {
16 16
17 class LayerImpl; 17 class LayerImpl;
18 class LayerTreeImpl; 18 class LayerTreeImpl;
19 19
20 class PushPropertiesCountingLayer : public Layer { 20 class PushPropertiesCountingLayer : public Layer {
21 public: 21 public:
22 static scoped_refptr<PushPropertiesCountingLayer> Create(); 22 static scoped_refptr<PushPropertiesCountingLayer> Create();
23 23
24 // Layer implementation. 24 // Layer implementation.
25 void PushPropertiesTo(LayerImpl* layer) override; 25 void PushPropertiesTo(LayerImpl* layer) override;
26 std::unique_ptr<LayerImpl> CreateLayerImpl(LayerTreeImpl* tree_impl) override; 26 std::unique_ptr<LayerImpl> CreateLayerImpl(LayerTreeImpl* tree_impl) override;
27 void ToLayerPropertiesProto(proto::LayerUpdate* layer_update, 27 void ToLayerPropertiesProto(proto::LayerProperties* proto) override;
28 bool inputs_only) override;
29 void SetTypeForProtoSerialization(proto::LayerNode* proto) const override; 28 void SetTypeForProtoSerialization(proto::LayerNode* proto) const override;
30 29
31 // Something to make this layer push properties, but no other layer. 30 // Something to make this layer push properties, but no other layer.
32 void MakePushProperties(); 31 void MakePushProperties();
33 32
34 size_t push_properties_count() const { return push_properties_count_; } 33 size_t push_properties_count() const { return push_properties_count_; }
35 void reset_push_properties_count() { push_properties_count_ = 0; } 34 void reset_push_properties_count() { push_properties_count_ = 0; }
36 35
37 void set_persist_needs_push_properties(bool persist) { 36 void set_persist_needs_push_properties(bool persist) {
38 persist_needs_push_properties_ = persist; 37 persist_needs_push_properties_ = persist;
39 } 38 }
40 39
41 private: 40 private:
42 PushPropertiesCountingLayer(); 41 PushPropertiesCountingLayer();
43 ~PushPropertiesCountingLayer() override; 42 ~PushPropertiesCountingLayer() override;
44 43
45 void AddPushPropertiesCount(); 44 void AddPushPropertiesCount();
46 45
47 size_t push_properties_count_; 46 size_t push_properties_count_;
48 bool persist_needs_push_properties_; 47 bool persist_needs_push_properties_;
49 48
50 DISALLOW_COPY_AND_ASSIGN(PushPropertiesCountingLayer); 49 DISALLOW_COPY_AND_ASSIGN(PushPropertiesCountingLayer);
51 }; 50 };
52 51
53 } // namespace cc 52 } // namespace cc
54 53
55 #endif // CC_TEST_PUSH_PROPERTIES_COUNTING_LAYER_H_ 54 #endif // CC_TEST_PUSH_PROPERTIES_COUNTING_LAYER_H_
OLDNEW
« no previous file with comments | « cc/test/fake_remote_compositor_bridge.cc ('k') | cc/test/push_properties_counting_layer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698