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

Side by Side Diff: Source/core/rendering/RenderListMarker.h

Issue 869323003: Oilpan: move RenderObjects off heap. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: review-induced improvements Created 5 years, 10 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 | Annotate | Revision Log
« no previous file with comments | « Source/core/rendering/RenderListItem.cpp ('k') | Source/core/rendering/RenderListMarker.cpp » ('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) 1999 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org)
3 * (C) 1999 Antti Koivisto (koivisto@kde.org) 3 * (C) 1999 Antti Koivisto (koivisto@kde.org)
4 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2009 Apple Inc. All rights reserv ed. 4 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2009 Apple Inc. All rights reserv ed.
5 * 5 *
6 * This library is free software; you can redistribute it and/or 6 * This library is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Library General Public 7 * modify it under the terms of the GNU Library General Public
8 * License as published by the Free Software Foundation; either 8 * License as published by the Free Software Foundation; either
9 * version 2 of the License, or (at your option) any later version. 9 * version 2 of the License, or (at your option) any later version.
10 * 10 *
(...skipping 21 matching lines...) Expand all
32 String listMarkerText(EListStyleType, int value); 32 String listMarkerText(EListStyleType, int value);
33 33
34 // Used to render the list item's marker. 34 // Used to render the list item's marker.
35 // The RenderListMarker always has to be a child of a RenderListItem. 35 // The RenderListMarker always has to be a child of a RenderListItem.
36 class RenderListMarker final : public RenderBox { 36 class RenderListMarker final : public RenderBox {
37 public: 37 public:
38 static RenderListMarker* createAnonymous(RenderListItem*); 38 static RenderListMarker* createAnonymous(RenderListItem*);
39 39
40 virtual ~RenderListMarker(); 40 virtual ~RenderListMarker();
41 virtual void destroy() override; 41 virtual void destroy() override;
42 virtual void trace(Visitor*) override;
43 42
44 const String& text() const { return m_text; } 43 const String& text() const { return m_text; }
45 44
46 bool isInside() const; 45 bool isInside() const;
47 46
48 void updateMarginsAndContent(); 47 void updateMarginsAndContent();
49 48
50 IntRect getRelativeMarkerRect(); 49 IntRect getRelativeMarkerRect();
51 LayoutRect localSelectionRect(); 50 LayoutRect localSelectionRect();
52 virtual bool isImage() const override; 51 virtual bool isImage() const override;
53 const StyleImage* image() { return m_image.get(); } 52 const StyleImage* image() { return m_image.get(); }
54 const RenderListItem* listItem() { return m_listItem.get(); } 53 const RenderListItem* listItem() { return m_listItem; }
55 54
56 static UChar listMarkerSuffix(EListStyleType, int value); 55 static UChar listMarkerSuffix(EListStyleType, int value);
57 56
58 void listItemStyleDidChange(); 57 void listItemStyleDidChange();
59 58
60 private: 59 private:
61 RenderListMarker(RenderListItem*); 60 RenderListMarker(RenderListItem*);
62 61
63 virtual const char* renderName() const override { return "RenderListMarker"; } 62 virtual const char* renderName() const override { return "RenderListMarker"; }
64 virtual void computePreferredLogicalWidths() override; 63 virtual void computePreferredLogicalWidths() override;
(...skipping 18 matching lines...) Expand all
83 virtual bool canBeSelectionLeaf() const override { return true; } 82 virtual bool canBeSelectionLeaf() const override { return true; }
84 83
85 void updateMargins(); 84 void updateMargins();
86 void updateContent(); 85 void updateContent();
87 86
88 virtual void styleWillChange(StyleDifference, const RenderStyle& newStyle) o verride; 87 virtual void styleWillChange(StyleDifference, const RenderStyle& newStyle) o verride;
89 virtual void styleDidChange(StyleDifference, const RenderStyle* oldStyle) ov erride; 88 virtual void styleDidChange(StyleDifference, const RenderStyle* oldStyle) ov erride;
90 89
91 String m_text; 90 String m_text;
92 RefPtr<StyleImage> m_image; 91 RefPtr<StyleImage> m_image;
93 RawPtrWillBeMember<RenderListItem> m_listItem; 92 RenderListItem* m_listItem;
94 }; 93 };
95 94
96 DEFINE_RENDER_OBJECT_TYPE_CASTS(RenderListMarker, isListMarker()); 95 DEFINE_RENDER_OBJECT_TYPE_CASTS(RenderListMarker, isListMarker());
97 96
98 } // namespace blink 97 } // namespace blink
99 98
100 #endif // RenderListMarker_h 99 #endif // RenderListMarker_h
OLDNEW
« no previous file with comments | « Source/core/rendering/RenderListItem.cpp ('k') | Source/core/rendering/RenderListMarker.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698