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

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

Issue 129173004: Update rendering classes to use OVERRIDE / FINAL when needed (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Rebase Created 6 years, 11 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 | « Source/core/rendering/RenderFileUploadControl.h ('k') | Source/core/rendering/RenderFrame.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 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
58 virtual ~RenderFlowThread() { }; 58 virtual ~RenderFlowThread() { };
59 59
60 virtual bool isRenderFlowThread() const OVERRIDE FINAL { return true; } 60 virtual bool isRenderFlowThread() const OVERRIDE FINAL { return true; }
61 61
62 virtual void layout() OVERRIDE FINAL; 62 virtual void layout() OVERRIDE FINAL;
63 63
64 // Always create a RenderLayer for the RenderFlowThread so that we 64 // Always create a RenderLayer for the RenderFlowThread so that we
65 // can easily avoid drawing the children directly. 65 // can easily avoid drawing the children directly.
66 virtual LayerType layerTypeRequired() const OVERRIDE FINAL { return NormalLa yer; } 66 virtual LayerType layerTypeRequired() const OVERRIDE FINAL { return NormalLa yer; }
67 67
68 virtual bool nodeAtPoint(const HitTestRequest&, HitTestResult&, const HitTes tLocation& locationInContainer, const LayoutPoint& accumulatedOffset, HitTestAct ion) OVERRIDE; 68 virtual bool nodeAtPoint(const HitTestRequest&, HitTestResult&, const HitTes tLocation& locationInContainer, const LayoutPoint& accumulatedOffset, HitTestAct ion) OVERRIDE FINAL;
69 69
70 void removeFlowChildInfo(RenderObject*); 70 void removeFlowChildInfo(RenderObject*);
71 #ifndef NDEBUG 71 #ifndef NDEBUG
72 bool hasChildInfo(RenderObject* child) const { return child && child->isBox( ) && m_regionRangeMap.contains(toRenderBox(child)); } 72 bool hasChildInfo(RenderObject* child) const { return child && child->isBox( ) && m_regionRangeMap.contains(toRenderBox(child)); }
73 #endif 73 #endif
74 74
75 virtual void addRegionToThread(RenderRegion*); 75 virtual void addRegionToThread(RenderRegion*);
76 virtual void removeRegionFromThread(RenderRegion*); 76 virtual void removeRegionFromThread(RenderRegion*);
77 const RenderRegionList& renderRegionList() const { return m_regionList; } 77 const RenderRegionList& renderRegionList() const { return m_regionList; }
78 78
(...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after
175 // Used to estimate the maximum height of the flow thread. 175 // Used to estimate the maximum height of the flow thread.
176 static LayoutUnit maxLogicalHeight() { return LayoutUnit::max() / 2; } 176 static LayoutUnit maxLogicalHeight() { return LayoutUnit::max() / 2; }
177 177
178 protected: 178 protected:
179 virtual const char* renderName() const = 0; 179 virtual const char* renderName() const = 0;
180 180
181 // Overridden by columns/pages to set up an initial logical width of the pag e width even when 181 // Overridden by columns/pages to set up an initial logical width of the pag e width even when
182 // no regions have been generated yet. 182 // no regions have been generated yet.
183 virtual LayoutUnit initialLogicalWidth() const { return 0; }; 183 virtual LayoutUnit initialLogicalWidth() const { return 0; };
184 184
185 virtual void mapLocalToContainer(const RenderLayerModelObject* repaintContai ner, TransformState&, MapCoordinatesFlags = ApplyContainerFlip, bool* wasFixed = 0) const OVERRIDE; 185 virtual void mapLocalToContainer(const RenderLayerModelObject* repaintContai ner, TransformState&, MapCoordinatesFlags = ApplyContainerFlip, bool* wasFixed = 0) const OVERRIDE FINAL;
186 186
187 void updateRegionsFlowThreadPortionRect(const RenderRegion* = 0); 187 void updateRegionsFlowThreadPortionRect(const RenderRegion* = 0);
188 bool shouldRepaint(const LayoutRect&) const; 188 bool shouldRepaint(const LayoutRect&) const;
189 bool regionInRange(const RenderRegion* targetRegion, const RenderRegion* sta rtRegion, const RenderRegion* endRegion) const; 189 bool regionInRange(const RenderRegion* targetRegion, const RenderRegion* sta rtRegion, const RenderRegion* endRegion) const;
190 190
191 LayoutRect computeRegionClippingRect(const LayoutPoint&, const LayoutRect&, const LayoutRect&) const; 191 LayoutRect computeRegionClippingRect(const LayoutPoint&, const LayoutRect&, const LayoutRect&) const;
192 192
193 void setDispatchRegionLayoutUpdateEvent(bool value) { m_dispatchRegionLayout UpdateEvent = value; } 193 void setDispatchRegionLayoutUpdateEvent(bool value) { m_dispatchRegionLayout UpdateEvent = value; }
194 bool shouldDispatchRegionLayoutUpdateEvent() { return m_dispatchRegionLayout UpdateEvent; } 194 bool shouldDispatchRegionLayoutUpdateEvent() { return m_dispatchRegionLayout UpdateEvent; }
195 195
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after
284 bool m_regionsHaveUniformLogicalWidth : 1; 284 bool m_regionsHaveUniformLogicalWidth : 1;
285 bool m_regionsHaveUniformLogicalHeight : 1; 285 bool m_regionsHaveUniformLogicalHeight : 1;
286 bool m_hasRegionsWithStyling : 1; 286 bool m_hasRegionsWithStyling : 1;
287 bool m_dispatchRegionLayoutUpdateEvent : 1; 287 bool m_dispatchRegionLayoutUpdateEvent : 1;
288 bool m_dispatchRegionOversetChangeEvent : 1; 288 bool m_dispatchRegionOversetChangeEvent : 1;
289 bool m_pageLogicalSizeChanged : 1; 289 bool m_pageLogicalSizeChanged : 1;
290 bool m_inConstrainedLayoutPhase : 1; 290 bool m_inConstrainedLayoutPhase : 1;
291 bool m_needsTwoPhasesLayout : 1; 291 bool m_needsTwoPhasesLayout : 1;
292 292
293 private: 293 private:
294 virtual bool supportsPartialLayout() const OVERRIDE { return false; } 294 virtual bool supportsPartialLayout() const OVERRIDE FINAL { return false; }
295 295
296 }; 296 };
297 297
298 DEFINE_RENDER_OBJECT_TYPE_CASTS(RenderFlowThread, isRenderFlowThread()); 298 DEFINE_RENDER_OBJECT_TYPE_CASTS(RenderFlowThread, isRenderFlowThread());
299 299
300 class CurrentRenderFlowThreadMaintainer { 300 class CurrentRenderFlowThreadMaintainer {
301 WTF_MAKE_NONCOPYABLE(CurrentRenderFlowThreadMaintainer); 301 WTF_MAKE_NONCOPYABLE(CurrentRenderFlowThreadMaintainer);
302 public: 302 public:
303 CurrentRenderFlowThreadMaintainer(RenderFlowThread*); 303 CurrentRenderFlowThreadMaintainer(RenderFlowThread*);
304 ~CurrentRenderFlowThreadMaintainer(); 304 ~CurrentRenderFlowThreadMaintainer();
305 private: 305 private:
306 RenderFlowThread* m_renderFlowThread; 306 RenderFlowThread* m_renderFlowThread;
307 RenderFlowThread* m_previousRenderFlowThread; 307 RenderFlowThread* m_previousRenderFlowThread;
308 }; 308 };
309 309
310 // These structures are used by PODIntervalTree for debugging. 310 // These structures are used by PODIntervalTree for debugging.
311 #ifndef NDEBUG 311 #ifndef NDEBUG
312 template <> struct ValueToString<LayoutUnit> { 312 template <> struct ValueToString<LayoutUnit> {
313 static String string(const LayoutUnit value) { return String::number(value.t oFloat()); } 313 static String string(const LayoutUnit value) { return String::number(value.t oFloat()); }
314 }; 314 };
315 315
316 template <> struct ValueToString<RenderRegion*> { 316 template <> struct ValueToString<RenderRegion*> {
317 static String string(const RenderRegion* value) { return String::format("%p" , value); } 317 static String string(const RenderRegion* value) { return String::format("%p" , value); }
318 }; 318 };
319 #endif 319 #endif
320 320
321 } // namespace WebCore 321 } // namespace WebCore
322 322
323 #endif // RenderFlowThread_h 323 #endif // RenderFlowThread_h
OLDNEW
« no previous file with comments | « Source/core/rendering/RenderFileUploadControl.h ('k') | Source/core/rendering/RenderFrame.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698