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

Side by Side Diff: Source/core/layout/LayoutFlowThread.h

Issue 1231363003: Fix virtual/override/final usage in Source/core/layout/. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 5 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/layout/LayoutFlexibleBox.h ('k') | Source/core/layout/LayoutFrame.h » ('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) 2011 Adobe Systems Incorporated. All rights reserved. 2 * Copyright (C) 2011 Adobe Systems Incorporated. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 7 *
8 * 1. Redistributions of source code must retain the above 8 * 1. Redistributions of source code must retain the above
9 * copyright notice, this list of conditions and the following 9 * copyright notice, this list of conditions and the following
10 * disclaimer. 10 * disclaimer.
(...skipping 30 matching lines...) Expand all
41 41
42 typedef ListHashSet<LayoutMultiColumnSet*> LayoutMultiColumnSetList; 42 typedef ListHashSet<LayoutMultiColumnSet*> LayoutMultiColumnSetList;
43 43
44 // LayoutFlowThread is used to collect all the layout objects that participate i n a flow thread. It 44 // LayoutFlowThread is used to collect all the layout objects that participate i n a flow thread. It
45 // will also help in doing the layout. However, it will not layout directly to s creen. Instead, 45 // will also help in doing the layout. However, it will not layout directly to s creen. Instead,
46 // LayoutMultiColumnSet objects will redirect their paint and nodeAtPoint method s to this 46 // LayoutMultiColumnSet objects will redirect their paint and nodeAtPoint method s to this
47 // object. Each LayoutMultiColumnSet will actually be a viewPort of the LayoutFl owThread. 47 // object. Each LayoutMultiColumnSet will actually be a viewPort of the LayoutFl owThread.
48 class CORE_EXPORT LayoutFlowThread: public LayoutBlockFlow { 48 class CORE_EXPORT LayoutFlowThread: public LayoutBlockFlow {
49 public: 49 public:
50 LayoutFlowThread(); 50 LayoutFlowThread();
51 virtual ~LayoutFlowThread() { } 51 ~LayoutFlowThread() override { }
52 52
53 virtual bool isLayoutFlowThread() const override final { return true; } 53 bool isLayoutFlowThread() const final { return true; }
54 virtual bool isLayoutMultiColumnFlowThread() const { return false; } 54 virtual bool isLayoutMultiColumnFlowThread() const { return false; }
55 virtual bool isLayoutPagedFlowThread() const { return false; } 55 virtual bool isLayoutPagedFlowThread() const { return false; }
56 56
57 virtual bool supportsPaintInvalidationStateCachedOffsets() const override { return false; } 57 bool supportsPaintInvalidationStateCachedOffsets() const override { return f alse; }
58 58
59 virtual void layout() override; 59 void layout() override;
60 60
61 // Always create a Layer for the LayoutFlowThread so that we 61 // Always create a Layer for the LayoutFlowThread so that we
62 // can easily avoid drawing the children directly. 62 // can easily avoid drawing the children directly.
63 virtual DeprecatedPaintLayerType layerTypeRequired() const override final { return NormalDeprecatedPaintLayer; } 63 DeprecatedPaintLayerType layerTypeRequired() const final { return NormalDepr ecatedPaintLayer; }
64 64
65 // Skip past a column spanner during flow thread layout. Spanners are not la id out inside the 65 // Skip past a column spanner during flow thread layout. Spanners are not la id out inside the
66 // flow thread, since the flow thread is not in a spanner's containing block chain (since the 66 // flow thread, since the flow thread is not in a spanner's containing block chain (since the
67 // containing block is the multicol container). 67 // containing block is the multicol container).
68 virtual void skipColumnSpanner(LayoutBox*, LayoutUnit logicalTopInFlowThread ) { } 68 virtual void skipColumnSpanner(LayoutBox*, LayoutUnit logicalTopInFlowThread ) { }
69 69
70 virtual void flowThreadDescendantWasInserted(LayoutObject*) { } 70 virtual void flowThreadDescendantWasInserted(LayoutObject*) { }
71 virtual void flowThreadDescendantWillBeRemoved(LayoutObject*) { } 71 virtual void flowThreadDescendantWillBeRemoved(LayoutObject*) { }
72 virtual void flowThreadDescendantStyleWillChange(LayoutObject*, StyleDiffere nce, const ComputedStyle& newStyle) { } 72 virtual void flowThreadDescendantStyleWillChange(LayoutObject*, StyleDiffere nce, const ComputedStyle& newStyle) { }
73 virtual void flowThreadDescendantStyleDidChange(LayoutObject*, StyleDifferen ce, const ComputedStyle& oldStyle) { } 73 virtual void flowThreadDescendantStyleDidChange(LayoutObject*, StyleDifferen ce, const ComputedStyle& oldStyle) { }
74 74
75 virtual bool nodeAtPoint(HitTestResult&, const HitTestLocation& locationInCo ntainer, const LayoutPoint& accumulatedOffset, HitTestAction) override final; 75 bool nodeAtPoint(HitTestResult&, const HitTestLocation& locationInContainer, const LayoutPoint& accumulatedOffset, HitTestAction) final;
76 76
77 virtual void addColumnSetToThread(LayoutMultiColumnSet*) = 0; 77 virtual void addColumnSetToThread(LayoutMultiColumnSet*) = 0;
78 virtual void removeColumnSetFromThread(LayoutMultiColumnSet*); 78 virtual void removeColumnSetFromThread(LayoutMultiColumnSet*);
79 79
80 virtual void computeLogicalHeight(LayoutUnit logicalHeight, LayoutUnit logic alTop, LogicalExtentComputedValues&) const override; 80 void computeLogicalHeight(LayoutUnit logicalHeight, LayoutUnit logicalTop, L ogicalExtentComputedValues&) const override;
81 81
82 bool hasColumnSets() const { return m_multiColumnSetList.size(); } 82 bool hasColumnSets() const { return m_multiColumnSetList.size(); }
83 83
84 void validateColumnSets(); 84 void validateColumnSets();
85 void invalidateColumnSets(); 85 void invalidateColumnSets();
86 bool hasValidColumnSetInfo() const { return !m_columnSetsInvalidated && !m_m ultiColumnSetList.isEmpty(); } 86 bool hasValidColumnSetInfo() const { return !m_columnSetsInvalidated && !m_m ultiColumnSetList.isEmpty(); }
87 87
88 virtual void mapRectToPaintInvalidationBacking(const LayoutBoxModelObject* p aintInvalidationContainer, LayoutRect&, const PaintInvalidationState*) const ove rride; 88 void mapRectToPaintInvalidationBacking(const LayoutBoxModelObject* paintInva lidationContainer, LayoutRect&, const PaintInvalidationState*) const override;
89 89
90 LayoutUnit pageLogicalHeightForOffset(LayoutUnit); 90 LayoutUnit pageLogicalHeightForOffset(LayoutUnit);
91 LayoutUnit pageRemainingLogicalHeightForOffset(LayoutUnit, PageBoundaryRule = IncludePageBoundary); 91 LayoutUnit pageRemainingLogicalHeightForOffset(LayoutUnit, PageBoundaryRule = IncludePageBoundary);
92 92
93 virtual void setPageBreak(LayoutUnit /*offset*/, LayoutUnit /*spaceShortage* /) { } 93 virtual void setPageBreak(LayoutUnit /*offset*/, LayoutUnit /*spaceShortage* /) { }
94 virtual void updateMinimumPageHeight(LayoutUnit /*offset*/, LayoutUnit /*min Height*/) { } 94 virtual void updateMinimumPageHeight(LayoutUnit /*offset*/, LayoutUnit /*min Height*/) { }
95 95
96 virtual bool addForcedColumnBreak(LayoutUnit, LayoutObject* breakChild, bool isBefore, LayoutUnit* offsetBreakAdjustment = nullptr) { return false; } 96 virtual bool addForcedColumnBreak(LayoutUnit, LayoutObject* breakChild, bool isBefore, LayoutUnit* offsetBreakAdjustment = nullptr) { return false; }
97 97
98 virtual bool isPageLogicalHeightKnown() const { return true; } 98 virtual bool isPageLogicalHeightKnown() const { return true; }
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after
157 }; 157 };
158 158
159 template <> struct ValueToString<LayoutMultiColumnSet*> { 159 template <> struct ValueToString<LayoutMultiColumnSet*> {
160 static String string(const LayoutMultiColumnSet* value) { return String::for mat("%p", value); } 160 static String string(const LayoutMultiColumnSet* value) { return String::for mat("%p", value); }
161 }; 161 };
162 #endif 162 #endif
163 163
164 } // namespace blink 164 } // namespace blink
165 165
166 #endif // LayoutFlowThread_h 166 #endif // LayoutFlowThread_h
OLDNEW
« no previous file with comments | « Source/core/layout/LayoutFlexibleBox.h ('k') | Source/core/layout/LayoutFrame.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698