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

Side by Side Diff: third_party/WebKit/Source/platform/graphics/CompositorMutation.h

Issue 2765053002: Avoid exposing cc::Layer tree to CompositorProxy (Closed)
Patch Set: Rebase onto blink reformat 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 unified diff | Download patch
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 CompositorMutation_h 5 #ifndef CompositorMutation_h
6 #define CompositorMutation_h 6 #define CompositorMutation_h
7 7
8 #include <memory> 8 #include <memory>
9 #include "platform/graphics/CompositorMutableProperties.h" 9 #include "platform/graphics/CompositorMutableProperties.h"
10 #include "platform/wtf/HashMap.h" 10 #include "platform/wtf/HashMap.h"
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
42 } 42 }
43 bool IsTransformMutated() const { 43 bool IsTransformMutated() const {
44 return mutated_flags_ & CompositorMutableProperty::kTransform; 44 return mutated_flags_ & CompositorMutableProperty::kTransform;
45 } 45 }
46 46
47 float Opacity() const { return opacity_; } 47 float Opacity() const { return opacity_; }
48 float ScrollLeft() const { return scroll_left_; } 48 float ScrollLeft() const { return scroll_left_; }
49 float ScrollTop() const { return scroll_top_; } 49 float ScrollTop() const { return scroll_top_; }
50 SkMatrix44 Transform() const { return transform_; } 50 SkMatrix44 Transform() const { return transform_; }
51 51
52 uint32_t mutatedProperties() const { return mutated_flags_; }
53
52 private: 54 private:
53 uint32_t mutated_flags_ = 0; 55 uint32_t mutated_flags_ = 0;
54 float opacity_ = 0; 56 float opacity_ = 0;
55 float scroll_left_ = 0; 57 float scroll_left_ = 0;
56 float scroll_top_ = 0; 58 float scroll_top_ = 0;
57 SkMatrix44 transform_; 59 SkMatrix44 transform_;
58 }; 60 };
59 61
60 struct CompositorMutations { 62 struct CompositorMutations {
61 HashMap<uint64_t, std::unique_ptr<CompositorMutation>> map; 63 HashMap<uint64_t, std::unique_ptr<CompositorMutation>> map;
62 }; 64 };
63 65
64 } // namespace blink 66 } // namespace blink
65 67
66 #endif // CompositorMutation_h 68 #endif // CompositorMutation_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698