OLD | NEW |
---|---|
1 /* | 1 /* |
2 * Copyright (C) 2000 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 2000 Lars Knoll (knoll@kde.org) |
3 * (C) 2000 Antti Koivisto (koivisto@kde.org) | 3 * (C) 2000 Antti Koivisto (koivisto@kde.org) |
4 * (C) 2000 Dirk Mueller (mueller@kde.org) | 4 * (C) 2000 Dirk Mueller (mueller@kde.org) |
5 * (C) 2004 Allan Sandfeld Jensen (kde@carewolf.com) | 5 * (C) 2004 Allan Sandfeld Jensen (kde@carewolf.com) |
6 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2012 Apple Inc. | 6 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2012 Apple Inc. |
7 * All rights reserved. | 7 * All rights reserved. |
8 * Copyright (C) 2009 Google Inc. All rights reserved. | 8 * Copyright (C) 2009 Google Inc. All rights reserved. |
9 * | 9 * |
10 * This library is free software; you can redistribute it and/or | 10 * This library is free software; you can redistribute it and/or |
(...skipping 1784 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
1795 void SetOnlyThisNeedsPaintPropertyUpdateForTesting() { | 1795 void SetOnlyThisNeedsPaintPropertyUpdateForTesting() { |
1796 layout_object_.bitfields_.SetNeedsPaintPropertyUpdate(true); | 1796 layout_object_.bitfields_.SetNeedsPaintPropertyUpdate(true); |
1797 } | 1797 } |
1798 void ClearNeedsPaintPropertyUpdateForTesting() { | 1798 void ClearNeedsPaintPropertyUpdateForTesting() { |
1799 layout_object_.bitfields_.SetNeedsPaintPropertyUpdate(false); | 1799 layout_object_.bitfields_.SetNeedsPaintPropertyUpdate(false); |
1800 } | 1800 } |
1801 #endif | 1801 #endif |
1802 | 1802 |
1803 protected: | 1803 protected: |
1804 friend class PaintPropertyTreeBuilder; | 1804 friend class PaintPropertyTreeBuilder; |
1805 friend class PrePaintTreeWalk; | |
1805 FRIEND_TEST_ALL_PREFIXES(AnimationCompositorAnimationsTest, | 1806 FRIEND_TEST_ALL_PREFIXES(AnimationCompositorAnimationsTest, |
1806 canStartAnimationOnCompositorTransformSPv2); | 1807 canStartAnimationOnCompositorTransformSPv2); |
1807 FRIEND_TEST_ALL_PREFIXES(AnimationCompositorAnimationsTest, | 1808 FRIEND_TEST_ALL_PREFIXES(AnimationCompositorAnimationsTest, |
1808 canStartAnimationOnCompositorEffectSPv2); | 1809 canStartAnimationOnCompositorEffectSPv2); |
1810 FRIEND_TEST_ALL_PREFIXES(PrePaintTreeWalkTest, ClipRects); | |
1809 | 1811 |
1810 // The following non-const functions for ObjectPaintProperties should only | 1812 // The following non-const functions for ObjectPaintProperties should only |
1811 // be called from PaintPropertyTreeBuilder. | 1813 // be called from PaintPropertyTreeBuilder. |
1812 ObjectPaintProperties& EnsurePaintProperties() { | 1814 ObjectPaintProperties& EnsurePaintProperties() { |
1813 return layout_object_.EnsureRarePaintData() | 1815 return layout_object_.EnsureRarePaintData() |
1814 .EnsureFragment() | 1816 .EnsureFragment() |
1815 .EnsurePaintProperties(); | 1817 .EnsurePaintProperties(); |
1816 } | 1818 } |
1817 ObjectPaintProperties* PaintProperties() { | 1819 ObjectPaintProperties* PaintProperties() { |
1818 if (auto* paint_data = layout_object_.GetRarePaintData()) | 1820 if (auto* paint_data = layout_object_.GetRarePaintData()) |
1819 return paint_data->PaintProperties(); | 1821 return paint_data->PaintProperties(); |
1820 return nullptr; | 1822 return nullptr; |
1821 } | 1823 } |
1822 void ClearPaintProperties() { | 1824 void ClearPaintProperties() { |
1823 if (auto* paint_data = layout_object_.GetRarePaintData()) { | 1825 if (auto* paint_data = layout_object_.GetRarePaintData()) { |
1824 if (auto* fragment = paint_data->Fragment()) | 1826 if (auto* fragment = paint_data->Fragment()) |
1825 fragment->ClearPaintProperties(); | 1827 fragment->ClearPaintProperties(); |
1826 } | 1828 } |
1827 } | 1829 } |
1830 FragmentData* FirstFragment() { | |
wkorman
2017/05/01 20:29:24
nit: add brief documentation, and move impl to .cp
chrishtr
2017/05/01 21:43:54
Done.
| |
1831 if (auto* paint_data = layout_object_.GetRarePaintData()) | |
1832 return paint_data->Fragment(); | |
1833 return nullptr; | |
1834 } | |
1828 | 1835 |
1829 // The following non-const functions for local border box properties should | 1836 // The following non-const functions for local border box properties should |
1830 // only be called from PaintPropertyTreeBuilder. | 1837 // only be called from PaintPropertyTreeBuilder. |
1831 void ClearLocalBorderBoxProperties() { | 1838 void ClearLocalBorderBoxProperties() { |
1832 if (auto* paint_data = layout_object_.GetRarePaintData()) | 1839 if (auto* paint_data = layout_object_.GetRarePaintData()) |
1833 paint_data->ClearLocalBorderBoxProperties(); | 1840 paint_data->ClearLocalBorderBoxProperties(); |
1834 } | 1841 } |
1835 void SetLocalBorderBoxProperties(PropertyTreeState& local_border_box) { | 1842 void SetLocalBorderBoxProperties(PropertyTreeState& local_border_box) { |
1836 return layout_object_.EnsureRarePaintData().SetLocalBorderBoxProperties( | 1843 return layout_object_.EnsureRarePaintData().SetLocalBorderBoxProperties( |
1837 local_border_box); | 1844 local_border_box); |
(...skipping 980 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
2818 CORE_EXPORT void showLineTree(const blink::LayoutObject*); | 2825 CORE_EXPORT void showLineTree(const blink::LayoutObject*); |
2819 CORE_EXPORT void showLayoutTree(const blink::LayoutObject* object1); | 2826 CORE_EXPORT void showLayoutTree(const blink::LayoutObject* object1); |
2820 // We don't make object2 an optional parameter so that showLayoutTree | 2827 // We don't make object2 an optional parameter so that showLayoutTree |
2821 // can be called from gdb easily. | 2828 // can be called from gdb easily. |
2822 CORE_EXPORT void showLayoutTree(const blink::LayoutObject* object1, | 2829 CORE_EXPORT void showLayoutTree(const blink::LayoutObject* object1, |
2823 const blink::LayoutObject* object2); | 2830 const blink::LayoutObject* object2); |
2824 | 2831 |
2825 #endif | 2832 #endif |
2826 | 2833 |
2827 #endif // LayoutObject_h | 2834 #endif // LayoutObject_h |
OLD | NEW |