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

Side by Side Diff: third_party/WebKit/Source/core/layout/LayoutObject.h

Issue 2844803007: Introduce FragmentData, and put ObjectPaintProperties into it. (Closed)
Patch Set: none Created 3 years, 7 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 | « no previous file | third_party/WebKit/Source/core/paint/BUILD.gn » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 1792 matching lines...) Expand 10 before | Expand all | Expand 10 after
1803 protected: 1803 protected:
1804 friend class PaintPropertyTreeBuilder; 1804 friend class PaintPropertyTreeBuilder;
1805 FRIEND_TEST_ALL_PREFIXES(AnimationCompositorAnimationsTest, 1805 FRIEND_TEST_ALL_PREFIXES(AnimationCompositorAnimationsTest,
1806 canStartAnimationOnCompositorTransformSPv2); 1806 canStartAnimationOnCompositorTransformSPv2);
1807 FRIEND_TEST_ALL_PREFIXES(AnimationCompositorAnimationsTest, 1807 FRIEND_TEST_ALL_PREFIXES(AnimationCompositorAnimationsTest,
1808 canStartAnimationOnCompositorEffectSPv2); 1808 canStartAnimationOnCompositorEffectSPv2);
1809 1809
1810 // The following non-const functions for ObjectPaintProperties should only 1810 // The following non-const functions for ObjectPaintProperties should only
1811 // be called from PaintPropertyTreeBuilder. 1811 // be called from PaintPropertyTreeBuilder.
1812 ObjectPaintProperties& EnsurePaintProperties() { 1812 ObjectPaintProperties& EnsurePaintProperties() {
1813 return layout_object_.EnsureRarePaintData().EnsurePaintProperties(); 1813 return layout_object_.EnsureRarePaintData()
1814 .EnsureFragment()
1815 .EnsurePaintProperties();
1814 } 1816 }
1815 ObjectPaintProperties* PaintProperties() { 1817 ObjectPaintProperties* PaintProperties() {
1816 if (auto* paint_data = layout_object_.GetRarePaintData()) 1818 if (auto* paint_data = layout_object_.GetRarePaintData())
1817 return paint_data->PaintProperties(); 1819 return paint_data->PaintProperties();
1818 return nullptr; 1820 return nullptr;
1819 } 1821 }
1820 void ClearPaintProperties() { 1822 void ClearPaintProperties() {
1821 if (auto* paint_data = layout_object_.GetRarePaintData()) 1823 if (auto* paint_data = layout_object_.GetRarePaintData()) {
1822 paint_data->ClearPaintProperties(); 1824 if (auto* fragment = paint_data->Fragment())
1825 fragment->ClearPaintProperties();
1826 }
1823 } 1827 }
1824 1828
1825 // The following non-const functions for local border box properties should 1829 // The following non-const functions for local border box properties should
1826 // only be called from PaintPropertyTreeBuilder. 1830 // only be called from PaintPropertyTreeBuilder.
1827 void ClearLocalBorderBoxProperties() { 1831 void ClearLocalBorderBoxProperties() {
1828 if (auto* paint_data = layout_object_.GetRarePaintData()) 1832 if (auto* paint_data = layout_object_.GetRarePaintData())
1829 paint_data->ClearLocalBorderBoxProperties(); 1833 paint_data->ClearLocalBorderBoxProperties();
1830 } 1834 }
1831 void SetLocalBorderBoxProperties(PropertyTreeState& local_border_box) { 1835 void SetLocalBorderBoxProperties(PropertyTreeState& local_border_box) {
1832 return layout_object_.EnsureRarePaintData().SetLocalBorderBoxProperties( 1836 return layout_object_.EnsureRarePaintData().SetLocalBorderBoxProperties(
(...skipping 994 matching lines...) Expand 10 before | Expand all | Expand 10 after
2827 CORE_EXPORT void showLineTree(const blink::LayoutObject*); 2831 CORE_EXPORT void showLineTree(const blink::LayoutObject*);
2828 CORE_EXPORT void showLayoutTree(const blink::LayoutObject* object1); 2832 CORE_EXPORT void showLayoutTree(const blink::LayoutObject* object1);
2829 // We don't make object2 an optional parameter so that showLayoutTree 2833 // We don't make object2 an optional parameter so that showLayoutTree
2830 // can be called from gdb easily. 2834 // can be called from gdb easily.
2831 CORE_EXPORT void showLayoutTree(const blink::LayoutObject* object1, 2835 CORE_EXPORT void showLayoutTree(const blink::LayoutObject* object1,
2832 const blink::LayoutObject* object2); 2836 const blink::LayoutObject* object2);
2833 2837
2834 #endif 2838 #endif
2835 2839
2836 #endif // LayoutObject_h 2840 #endif // LayoutObject_h
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/paint/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698