| OLD | NEW |
| 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_BLINK_WEB_LAYER_IMPL_H_ | 5 #ifndef CC_BLINK_WEB_LAYER_IMPL_H_ |
| 6 #define CC_BLINK_WEB_LAYER_IMPL_H_ | 6 #define CC_BLINK_WEB_LAYER_IMPL_H_ |
| 7 | 7 |
| 8 #include <stddef.h> | 8 #include <stddef.h> |
| 9 #include <stdint.h> | 9 #include <stdint.h> |
| 10 | 10 |
| (...skipping 27 matching lines...) Expand all Loading... |
| 38 } | 38 } |
| 39 } | 39 } |
| 40 | 40 |
| 41 namespace cc { | 41 namespace cc { |
| 42 class FilterOperations; | 42 class FilterOperations; |
| 43 class Layer; | 43 class Layer; |
| 44 } | 44 } |
| 45 | 45 |
| 46 namespace cc_blink { | 46 namespace cc_blink { |
| 47 | 47 |
| 48 class WebLayerImpl : public blink::WebLayer { | 48 class CC_BLINK_EXPORT WebLayerImpl : public NON_EXPORTED_BASE(blink::WebLayer) { |
| 49 public: | 49 public: |
| 50 CC_BLINK_EXPORT WebLayerImpl(); | 50 WebLayerImpl(); |
| 51 CC_BLINK_EXPORT explicit WebLayerImpl(scoped_refptr<cc::Layer>); | 51 explicit WebLayerImpl(scoped_refptr<cc::Layer>); |
| 52 ~WebLayerImpl() override; | 52 ~WebLayerImpl() override; |
| 53 | 53 |
| 54 CC_BLINK_EXPORT cc::Layer* layer() const; | 54 cc::Layer* layer() const; |
| 55 | 55 |
| 56 // If set to true, content opaqueness cannot be changed using setOpaque. | 56 // If set to true, content opaqueness cannot be changed using setOpaque. |
| 57 // However, it can still be modified using SetContentsOpaque on the | 57 // However, it can still be modified using SetContentsOpaque on the |
| 58 // cc::Layer. | 58 // cc::Layer. |
| 59 CC_BLINK_EXPORT void SetContentsOpaqueIsFixed(bool fixed); | 59 void SetContentsOpaqueIsFixed(bool fixed); |
| 60 | 60 |
| 61 // WebLayer implementation. | 61 // WebLayer implementation. |
| 62 int id() const override; | 62 int id() const override; |
| 63 void invalidateRect(const blink::WebRect&) override; | 63 void invalidateRect(const blink::WebRect&) override; |
| 64 void invalidate() override; | 64 void invalidate() override; |
| 65 void addChild(blink::WebLayer* child) override; | 65 void addChild(blink::WebLayer* child) override; |
| 66 void insertChild(blink::WebLayer* child, size_t index) override; | 66 void insertChild(blink::WebLayer* child, size_t index) override; |
| 67 void replaceChild(blink::WebLayer* reference, | 67 void replaceChild(blink::WebLayer* reference, |
| 68 blink::WebLayer* new_layer) override; | 68 blink::WebLayer* new_layer) override; |
| 69 void removeFromParent() override; | 69 void removeFromParent() override; |
| 70 void removeAllChildren() override; | 70 void removeAllChildren() override; |
| 71 void setBounds(const blink::WebSize& bounds) override; | 71 void setBounds(const blink::WebSize& bounds) override; |
| 72 blink::WebSize bounds() const override; | 72 blink::WebSize bounds() const override; |
| 73 void setMasksToBounds(bool masks_to_bounds) override; | 73 void setMasksToBounds(bool masks_to_bounds) override; |
| 74 bool masksToBounds() const override; | 74 bool masksToBounds() const override; |
| 75 void setMaskLayer(blink::WebLayer* mask) override; | 75 void setMaskLayer(blink::WebLayer* mask) override; |
| 76 void setReplicaLayer(blink::WebLayer* replica) override; | 76 void setReplicaLayer(blink::WebLayer* replica) override; |
| 77 void setOpacity(float opacity) override; | 77 void setOpacity(float opacity) override; |
| 78 float opacity() const override; | 78 float opacity() const override; |
| 79 void setBlendMode(blink::WebBlendMode blend_mode) override; | 79 void setBlendMode(blink::WebBlendMode blend_mode) override; |
| 80 blink::WebBlendMode blendMode() const override; | 80 blink::WebBlendMode blendMode() const override; |
| 81 void setIsRootForIsolatedGroup(bool root) override; | 81 void setIsRootForIsolatedGroup(bool root) override; |
| 82 bool isRootForIsolatedGroup() override; | 82 bool isRootForIsolatedGroup() override; |
| 83 CC_BLINK_EXPORT void setOpaque(bool opaque) override; | 83 void setOpaque(bool opaque) override; |
| 84 bool opaque() const override; | 84 bool opaque() const override; |
| 85 void setPosition(const blink::WebFloatPoint& position) override; | 85 void setPosition(const blink::WebFloatPoint& position) override; |
| 86 blink::WebFloatPoint position() const override; | 86 blink::WebFloatPoint position() const override; |
| 87 void setTransform(const SkMatrix44& transform) override; | 87 void setTransform(const SkMatrix44& transform) override; |
| 88 void setTransformOrigin(const blink::WebFloatPoint3D& point) override; | 88 void setTransformOrigin(const blink::WebFloatPoint3D& point) override; |
| 89 blink::WebFloatPoint3D transformOrigin() const override; | 89 blink::WebFloatPoint3D transformOrigin() const override; |
| 90 SkMatrix44 transform() const override; | 90 SkMatrix44 transform() const override; |
| 91 void setDrawsContent(bool draws_content) override; | 91 void setDrawsContent(bool draws_content) override; |
| 92 bool drawsContent() const override; | 92 bool drawsContent() const override; |
| 93 void setDoubleSided(bool double_sided) override; | 93 void setDoubleSided(bool double_sided) override; |
| (...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 142 | 142 |
| 143 bool contents_opaque_is_fixed_; | 143 bool contents_opaque_is_fixed_; |
| 144 | 144 |
| 145 private: | 145 private: |
| 146 DISALLOW_COPY_AND_ASSIGN(WebLayerImpl); | 146 DISALLOW_COPY_AND_ASSIGN(WebLayerImpl); |
| 147 }; | 147 }; |
| 148 | 148 |
| 149 } // namespace cc_blink | 149 } // namespace cc_blink |
| 150 | 150 |
| 151 #endif // CC_BLINK_WEB_LAYER_IMPL_H_ | 151 #endif // CC_BLINK_WEB_LAYER_IMPL_H_ |
| OLD | NEW |