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

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

Issue 569683004: Factor painting code from RenderBlock into BlockPainter. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Fixed Created 6 years, 3 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/InlineBox.cpp ('k') | Source/core/rendering/RenderBlock.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 * (C) 2007 David Smith (catfish.man@gmail.com) 4 * (C) 2007 David Smith (catfish.man@gmail.com)
5 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. All r ights reserved. 5 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. All r ights reserved.
6 * 6 *
7 * This library is free software; you can redistribute it and/or 7 * This library is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU Library General Public 8 * modify it under the terms of the GNU Library General Public
9 * License as published by the Free Software Foundation; either 9 * License as published by the Free Software Foundation; either
10 * version 2 of the License, or (at your option) any later version. 10 * version 2 of the License, or (at your option) any later version.
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
46 class WordMeasurement; 46 class WordMeasurement;
47 47
48 template <class Run> class BidiRunList; 48 template <class Run> class BidiRunList;
49 typedef WTF::ListHashSet<RenderBox*, 16> TrackedRendererListHashSet; 49 typedef WTF::ListHashSet<RenderBox*, 16> TrackedRendererListHashSet;
50 typedef WTF::HashMap<const RenderBlock*, OwnPtr<TrackedRendererListHashSet> > Tr ackedDescendantsMap; 50 typedef WTF::HashMap<const RenderBlock*, OwnPtr<TrackedRendererListHashSet> > Tr ackedDescendantsMap;
51 typedef WTF::HashMap<const RenderBox*, OwnPtr<HashSet<RenderBlock*> > > TrackedC ontainerMap; 51 typedef WTF::HashMap<const RenderBox*, OwnPtr<HashSet<RenderBlock*> > > TrackedC ontainerMap;
52 typedef Vector<WordMeasurement, 64> WordMeasurements; 52 typedef Vector<WordMeasurement, 64> WordMeasurements;
53 53
54 enum ContainingBlockState { NewContainingBlock, SameContainingBlock }; 54 enum ContainingBlockState { NewContainingBlock, SameContainingBlock };
55 55
56 typedef WTF::HashMap<RenderBlock*, OwnPtr<ListHashSet<RenderInline*> > > Continu ationOutlineTableMap;
57
58 ContinuationOutlineTableMap* continuationOutlineTable();
59
56 class RenderBlock : public RenderBox { 60 class RenderBlock : public RenderBox {
57 public: 61 public:
58 virtual void destroy() OVERRIDE; 62 virtual void destroy() OVERRIDE;
59 virtual void trace(Visitor*) OVERRIDE; 63 virtual void trace(Visitor*) OVERRIDE;
60 friend class LineLayoutState; 64 friend class LineLayoutState;
61 65
62 protected: 66 protected:
63 explicit RenderBlock(ContainerNode*); 67 explicit RenderBlock(ContainerNode*);
64 virtual ~RenderBlock(); 68 virtual ~RenderBlock();
65 69
66 public: 70 public:
67 RenderObject* firstChild() const { ASSERT(children() == virtualChildren()); return children()->firstChild(); } 71 RenderObject* firstChild() const { ASSERT(children() == virtualChildren()); return children()->firstChild(); }
68 RenderObject* lastChild() const { ASSERT(children() == virtualChildren()); r eturn children()->lastChild(); } 72 RenderObject* lastChild() const { ASSERT(children() == virtualChildren()); r eturn children()->lastChild(); }
69 73
70 // If you have a RenderBlock, use firstChild or lastChild instead. 74 // If you have a RenderBlock, use firstChild or lastChild instead.
71 void slowFirstChild() const WTF_DELETED_FUNCTION; 75 void slowFirstChild() const WTF_DELETED_FUNCTION;
72 void slowLastChild() const WTF_DELETED_FUNCTION; 76 void slowLastChild() const WTF_DELETED_FUNCTION;
73 77
74 const RenderObjectChildList* children() const { return &m_children; } 78 const RenderObjectChildList* children() const { return &m_children; }
75 RenderObjectChildList* children() { return &m_children; } 79 RenderObjectChildList* children() { return &m_children; }
76 80
77 bool beingDestroyed() const { return m_beingDestroyed; } 81 bool beingDestroyed() const { return m_beingDestroyed; }
78 82
79 // These two functions are overridden for inline-block. 83 // These two functions are overridden for inline-block.
80 virtual LayoutUnit lineHeight(bool firstLine, LineDirectionMode, LinePositio nMode = PositionOnContainingLine) const OVERRIDE FINAL; 84 virtual LayoutUnit lineHeight(bool firstLine, LineDirectionMode, LinePositio nMode = PositionOnContainingLine) const OVERRIDE FINAL;
81 virtual int baselinePosition(FontBaseline, bool firstLine, LineDirectionMode , LinePositionMode = PositionOnContainingLine) const OVERRIDE; 85 virtual int baselinePosition(FontBaseline, bool firstLine, LineDirectionMode , LinePositionMode = PositionOnContainingLine) const OVERRIDE;
82 86
83 LayoutUnit minLineHeightForReplacedRenderer(bool isFirstLine, LayoutUnit rep lacedHeight) const; 87 LayoutUnit minLineHeightForReplacedRenderer(bool isFirstLine, LayoutUnit rep lacedHeight) const;
84 88
85 protected:
86 RenderLineBoxList* lineBoxes() { return &m_lineBoxes; } 89 RenderLineBoxList* lineBoxes() { return &m_lineBoxes; }
87 90
91 protected:
88 InlineFlowBox* firstLineBox() const { return m_lineBoxes.firstLineBox(); } 92 InlineFlowBox* firstLineBox() const { return m_lineBoxes.firstLineBox(); }
89 InlineFlowBox* lastLineBox() const { return m_lineBoxes.lastLineBox(); } 93 InlineFlowBox* lastLineBox() const { return m_lineBoxes.lastLineBox(); }
90 94
91 RootInlineBox* firstRootBox() const { return static_cast<RootInlineBox*>(fir stLineBox()); } 95 RootInlineBox* firstRootBox() const { return static_cast<RootInlineBox*>(fir stLineBox()); }
92 RootInlineBox* lastRootBox() const { return static_cast<RootInlineBox*>(last LineBox()); } 96 RootInlineBox* lastRootBox() const { return static_cast<RootInlineBox*>(last LineBox()); }
93 97
94 public: 98 public:
95 // FIXME-BLOCKFLOW: Remove virtualizaion when all callers have moved to Rend erBlockFlow 99 // FIXME-BLOCKFLOW: Remove virtualizaion when all callers have moved to Rend erBlockFlow
96 virtual void deleteLineBoxTree(); 100 virtual void deleteLineBoxTree();
97 101
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after
172 RootInlineBox* lineAtIndex(int) const; 176 RootInlineBox* lineAtIndex(int) const;
173 int lineCount(const RootInlineBox* = 0, bool* = 0) const; 177 int lineCount(const RootInlineBox* = 0, bool* = 0) const;
174 int heightForLineCount(int); 178 int heightForLineCount(int);
175 void clearTruncation(); 179 void clearTruncation();
176 180
177 void adjustRectForColumns(LayoutRect&) const; 181 void adjustRectForColumns(LayoutRect&) const;
178 virtual LayoutSize columnOffset(const LayoutPoint&) const OVERRIDE; 182 virtual LayoutSize columnOffset(const LayoutPoint&) const OVERRIDE;
179 void adjustForColumnRect(LayoutSize& offset, const LayoutPoint& locationInCo ntainer) const; 183 void adjustForColumnRect(LayoutSize& offset, const LayoutPoint& locationInCo ntainer) const;
180 184
181 void addContinuationWithOutline(RenderInline*); 185 void addContinuationWithOutline(RenderInline*);
182 bool paintsContinuationOutline(RenderInline*);
183 186
184 virtual RenderBoxModelObject* virtualContinuation() const OVERRIDE FINAL { r eturn continuation(); } 187 virtual RenderBoxModelObject* virtualContinuation() const OVERRIDE FINAL { r eturn continuation(); }
185 bool isAnonymousBlockContinuation() const { return continuation() && isAnony mousBlock(); } 188 bool isAnonymousBlockContinuation() const { return continuation() && isAnony mousBlock(); }
186 RenderInline* inlineElementContinuation() const; 189 RenderInline* inlineElementContinuation() const;
187 RenderBlock* blockElementContinuation() const; 190 RenderBlock* blockElementContinuation() const;
188 191
189 using RenderBoxModelObject::continuation; 192 using RenderBoxModelObject::continuation;
190 using RenderBoxModelObject::setContinuation; 193 using RenderBoxModelObject::setContinuation;
191 194
192 static RenderBlock* createAnonymousWithParentRendererAndDisplay(const Render Object*, EDisplay = BLOCK); 195 static RenderBlock* createAnonymousWithParentRendererAndDisplay(const Render Object*, EDisplay = BLOCK);
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
230 virtual bool nodeAtPoint(const HitTestRequest&, HitTestResult&, const HitTes tLocation& locationInContainer, const LayoutPoint& accumulatedOffset, HitTestAct ion) OVERRIDE; 233 virtual bool nodeAtPoint(const HitTestRequest&, HitTestResult&, const HitTes tLocation& locationInContainer, const LayoutPoint& accumulatedOffset, HitTestAct ion) OVERRIDE;
231 234
232 virtual void scrollbarsChanged(bool /*horizontalScrollbarChanged*/, bool /*v erticalScrollbarChanged*/) { } 235 virtual void scrollbarsChanged(bool /*horizontalScrollbarChanged*/, bool /*v erticalScrollbarChanged*/) { }
233 236
234 LayoutUnit availableLogicalWidthForContent() const { return max<LayoutUnit>( 0, logicalRightOffsetForContent() - logicalLeftOffsetForContent()); } 237 LayoutUnit availableLogicalWidthForContent() const { return max<LayoutUnit>( 0, logicalRightOffsetForContent() - logicalLeftOffsetForContent()); }
235 LayoutUnit logicalLeftOffsetForContent() const { return isHorizontalWritingM ode() ? borderLeft() + paddingLeft() : borderTop() + paddingTop(); } 238 LayoutUnit logicalLeftOffsetForContent() const { return isHorizontalWritingM ode() ? borderLeft() + paddingLeft() : borderTop() + paddingTop(); }
236 LayoutUnit logicalRightOffsetForContent() const { return logicalLeftOffsetFo rContent() + availableLogicalWidth(); } 239 LayoutUnit logicalRightOffsetForContent() const { return logicalLeftOffsetFo rContent() + availableLogicalWidth(); }
237 LayoutUnit startOffsetForContent() const { return style()->isLeftToRightDire ction() ? logicalLeftOffsetForContent() : logicalWidth() - logicalRightOffsetFor Content(); } 240 LayoutUnit startOffsetForContent() const { return style()->isLeftToRightDire ction() ? logicalLeftOffsetForContent() : logicalWidth() - logicalRightOffsetFor Content(); }
238 LayoutUnit endOffsetForContent() const { return !style()->isLeftToRightDirec tion() ? logicalLeftOffsetForContent() : logicalWidth() - logicalRightOffsetForC ontent(); } 241 LayoutUnit endOffsetForContent() const { return !style()->isLeftToRightDirec tion() ? logicalLeftOffsetForContent() : logicalWidth() - logicalRightOffsetForC ontent(); }
239 242
243 virtual LayoutUnit logicalLeftSelectionOffset(const RenderBlock* rootBlock, LayoutUnit position) const;
244 virtual LayoutUnit logicalRightSelectionOffset(const RenderBlock* rootBlock, LayoutUnit position) const;
245
246 GapRects selectionGaps(const RenderBlock* rootBlock, const LayoutPoint& root BlockPhysicalPosition, const LayoutSize& offsetFromRootBlock,
247 LayoutUnit& lastLogicalTop, LayoutUnit& lastLogicalLeft, LayoutUnit& las tLogicalRight, const PaintInfo* = 0) const;
248
240 #if ENABLE(ASSERT) 249 #if ENABLE(ASSERT)
241 void checkPositionedObjectsNeedLayout(); 250 void checkPositionedObjectsNeedLayout();
251 bool paintsContinuationOutline(RenderInline* flow);
242 #endif 252 #endif
243 #ifndef NDEBUG 253 #ifndef NDEBUG
244 void showLineTreeAndMark(const InlineBox* = 0, const char* = 0, const Inline Box* = 0, const char* = 0, const RenderObject* = 0) const; 254 void showLineTreeAndMark(const InlineBox* = 0, const char* = 0, const Inline Box* = 0, const char* = 0, const RenderObject* = 0) const;
245 #endif 255 #endif
246 256
247 // inline-block elements paint all phases atomically. This function ensures that. Certain other elements
248 // (grid items, flex items) require this behavior as well, and this function exists as a helper for them.
249 // It is expected that the caller will call this function independent of the value of paintInfo.phase.
250 static void paintAsInlineBlock(RenderObject*, PaintInfo&, const LayoutPoint& );
251
252 bool recalcChildOverflowAfterStyleChange(); 257 bool recalcChildOverflowAfterStyleChange();
253 bool recalcOverflowAfterStyleChange(); 258 bool recalcOverflowAfterStyleChange();
254 259
255 protected: 260 protected:
256 virtual void willBeDestroyed() OVERRIDE; 261 virtual void willBeDestroyed() OVERRIDE;
257 262
258 void dirtyForLayoutFromPercentageHeightDescendants(SubtreeLayoutScope&); 263 void dirtyForLayoutFromPercentageHeightDescendants(SubtreeLayoutScope&);
259 264
260 virtual void layout() OVERRIDE; 265 virtual void layout() OVERRIDE;
261 virtual bool updateImageLoadingPriorities() OVERRIDE FINAL; 266 virtual bool updateImageLoadingPriorities() OVERRIDE FINAL;
262 267
263 enum PositionedLayoutBehavior { 268 enum PositionedLayoutBehavior {
264 DefaultLayout, 269 DefaultLayout,
265 LayoutOnlyFixedPositionedObjects, 270 LayoutOnlyFixedPositionedObjects,
266 ForcedLayoutAfterContainingBlockMoved 271 ForcedLayoutAfterContainingBlockMoved
267 }; 272 };
268 273
269 void layoutPositionedObjects(bool relayoutChildren, PositionedLayoutBehavior = DefaultLayout); 274 void layoutPositionedObjects(bool relayoutChildren, PositionedLayoutBehavior = DefaultLayout);
270 void markFixedPositionObjectForLayoutIfNeeded(RenderObject* child, SubtreeLa youtScope&); 275 void markFixedPositionObjectForLayoutIfNeeded(RenderObject* child, SubtreeLa youtScope&);
271 276
272 LayoutUnit marginIntrinsicLogicalWidthForChild(RenderBox* child) const; 277 LayoutUnit marginIntrinsicLogicalWidthForChild(RenderBox* child) const;
273 278
274 int beforeMarginInLineDirection(LineDirectionMode) const; 279 int beforeMarginInLineDirection(LineDirectionMode) const;
275 280
276 virtual void paint(PaintInfo&, const LayoutPoint&) OVERRIDE; 281 virtual void paint(PaintInfo&, const LayoutPoint&) OVERRIDE;
282 public:
277 virtual void paintObject(PaintInfo&, const LayoutPoint&) OVERRIDE; 283 virtual void paintObject(PaintInfo&, const LayoutPoint&) OVERRIDE;
278 virtual void paintChildren(PaintInfo&, const LayoutPoint&); 284 virtual void paintChildren(PaintInfo&, const LayoutPoint&);
279 void paintChild(RenderBox*, PaintInfo&, const LayoutPoint&);
280 void paintChildAsInlineBlock(RenderBox*, PaintInfo&, const LayoutPoint&);
281 285
286 // FIXME-BLOCKFLOW: Remove virtualizaion when all callers have moved to Rend erBlockFlow
287 virtual void paintFloats(PaintInfo&, const LayoutPoint&, bool) { }
288
289 protected:
282 virtual void adjustInlineDirectionLineBounds(unsigned /* expansionOpportunit yCount */, float& /* logicalLeft */, float& /* logicalWidth */) const { } 290 virtual void adjustInlineDirectionLineBounds(unsigned /* expansionOpportunit yCount */, float& /* logicalLeft */, float& /* logicalWidth */) const { }
283 291
284 virtual void computeIntrinsicLogicalWidths(LayoutUnit& minLogicalWidth, Layo utUnit& maxLogicalWidth) const OVERRIDE; 292 virtual void computeIntrinsicLogicalWidths(LayoutUnit& minLogicalWidth, Layo utUnit& maxLogicalWidth) const OVERRIDE;
285 virtual void computePreferredLogicalWidths() OVERRIDE; 293 virtual void computePreferredLogicalWidths() OVERRIDE;
286 void adjustIntrinsicLogicalWidthsForColumns(LayoutUnit& minLogicalWidth, Lay outUnit& maxLogicalWidth) const; 294 void adjustIntrinsicLogicalWidthsForColumns(LayoutUnit& minLogicalWidth, Lay outUnit& maxLogicalWidth) const;
287 295
288 virtual int firstLineBoxBaseline() const OVERRIDE; 296 virtual int firstLineBoxBaseline() const OVERRIDE;
289 virtual int inlineBlockBaseline(LineDirectionMode) const OVERRIDE; 297 virtual int inlineBlockBaseline(LineDirectionMode) const OVERRIDE;
290 int lastLineBoxBaseline(LineDirectionMode) const; 298 int lastLineBoxBaseline(LineDirectionMode) const;
291 299
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after
355 virtual bool isSelfCollapsingBlock() const OVERRIDE; 363 virtual bool isSelfCollapsingBlock() const OVERRIDE;
356 364
357 void insertIntoTrackedRendererMaps(RenderBox* descendant, TrackedDescendants Map*&, TrackedContainerMap*&); 365 void insertIntoTrackedRendererMaps(RenderBox* descendant, TrackedDescendants Map*&, TrackedContainerMap*&);
358 static void removeFromTrackedRendererMaps(RenderBox* descendant, TrackedDesc endantsMap*&, TrackedContainerMap*&); 366 static void removeFromTrackedRendererMaps(RenderBox* descendant, TrackedDesc endantsMap*&, TrackedContainerMap*&);
359 367
360 void createFirstLetterRenderer(RenderObject* firstLetterBlock, RenderText& c urrentChild, unsigned length); 368 void createFirstLetterRenderer(RenderObject* firstLetterBlock, RenderText& c urrentChild, unsigned length);
361 void updateFirstLetterStyle(RenderObject* firstLetterBlock, RenderObject* fi rstLetterContainer); 369 void updateFirstLetterStyle(RenderObject* firstLetterBlock, RenderObject* fi rstLetterContainer);
362 370
363 Node* nodeForHitTest() const; 371 Node* nodeForHitTest() const;
364 372
365 // FIXME-BLOCKFLOW: Remove virtualizaion when all callers have moved to Rend erBlockFlow 373 private:
366 virtual void paintFloats(PaintInfo&, const LayoutPoint&, bool) { }
367 void paintContents(PaintInfo&, const LayoutPoint&);
368 void paintColumnContents(PaintInfo&, const LayoutPoint&, bool paintFloats = false);
369 void paintColumnRules(PaintInfo&, const LayoutPoint&);
370 void paintSelection(PaintInfo&, const LayoutPoint&);
371 void paintCarets(PaintInfo&, const LayoutPoint&);
372
373 bool hasCaret() const;
374
375 virtual bool avoidsFloats() const OVERRIDE { return true; } 374 virtual bool avoidsFloats() const OVERRIDE { return true; }
376 375
377 bool hitTestColumns(const HitTestRequest&, HitTestResult&, const HitTestLoca tion& locationInContainer, const LayoutPoint& accumulatedOffset, HitTestAction); 376 bool hitTestColumns(const HitTestRequest&, HitTestResult&, const HitTestLoca tion& locationInContainer, const LayoutPoint& accumulatedOffset, HitTestAction);
378 bool hitTestContents(const HitTestRequest&, HitTestResult&, const HitTestLoc ation& locationInContainer, const LayoutPoint& accumulatedOffset, HitTestAction) ; 377 bool hitTestContents(const HitTestRequest&, HitTestResult&, const HitTestLoc ation& locationInContainer, const LayoutPoint& accumulatedOffset, HitTestAction) ;
379 // FIXME-BLOCKFLOW: Remove virtualizaion when all callers have moved to Rend erBlockFlow 378 // FIXME-BLOCKFLOW: Remove virtualizaion when all callers have moved to Rend erBlockFlow
380 virtual bool hitTestFloats(const HitTestRequest&, HitTestResult&, const HitT estLocation&, const LayoutPoint&) { return false; } 379 virtual bool hitTestFloats(const HitTestRequest&, HitTestResult&, const HitT estLocation&, const LayoutPoint&) { return false; }
381 380
382 virtual bool isPointInOverflowControl(HitTestResult&, const LayoutPoint& loc ationInContainer, const LayoutPoint& accumulatedOffset); 381 virtual bool isPointInOverflowControl(HitTestResult&, const LayoutPoint& loc ationInContainer, const LayoutPoint& accumulatedOffset);
383 382
384 void computeBlockPreferredLogicalWidths(LayoutUnit& minLogicalWidth, LayoutU nit& maxLogicalWidth) const; 383 void computeBlockPreferredLogicalWidths(LayoutUnit& minLogicalWidth, LayoutU nit& maxLogicalWidth) const;
385 384
386 // Obtains the nearest enclosing block (including this block) that contribut es a first-line style to our inline 385 // Obtains the nearest enclosing block (including this block) that contribut es a first-line style to our inline
387 // children. 386 // children.
388 virtual RenderBlock* firstLineBlock() const OVERRIDE; 387 virtual RenderBlock* firstLineBlock() const OVERRIDE;
389 388
390 virtual LayoutRect rectWithOutlineForPaintInvalidation(const RenderLayerMode lObject* paintInvalidationContainer, LayoutUnit outlineWidth, const PaintInvalid ationState* = 0) const OVERRIDE FINAL; 389 virtual LayoutRect rectWithOutlineForPaintInvalidation(const RenderLayerMode lObject* paintInvalidationContainer, LayoutUnit outlineWidth, const PaintInvalid ationState* = 0) const OVERRIDE FINAL;
391 390
392 virtual RenderObject* hoverAncestor() const OVERRIDE FINAL; 391 virtual RenderObject* hoverAncestor() const OVERRIDE FINAL;
393 virtual void updateDragState(bool dragOn) OVERRIDE FINAL; 392 virtual void updateDragState(bool dragOn) OVERRIDE FINAL;
394 virtual void childBecameNonInline(RenderObject* child) OVERRIDE FINAL; 393 virtual void childBecameNonInline(RenderObject* child) OVERRIDE FINAL;
395 394
396 virtual LayoutRect selectionRectForPaintInvalidation(const RenderLayerModelO bject* paintInvalidationContainer, bool /*clipToVisibleContent*/) const OVERRIDE FINAL 395 virtual LayoutRect selectionRectForPaintInvalidation(const RenderLayerModelO bject* paintInvalidationContainer, bool /*clipToVisibleContent*/) const OVERRIDE FINAL
397 { 396 {
398 return selectionGapRectsForPaintInvalidation(paintInvalidationContainer) ; 397 return selectionGapRectsForPaintInvalidation(paintInvalidationContainer) ;
399 } 398 }
400 bool isSelectionRoot() const; 399 bool isSelectionRoot() const;
401 GapRects selectionGaps(const RenderBlock* rootBlock, const LayoutPoint& root BlockPhysicalPosition, const LayoutSize& offsetFromRootBlock,
402 LayoutUnit& lastLogicalTop, LayoutUnit& lastLogicalLe ft, LayoutUnit& lastLogicalRight, const PaintInfo* = 0) const;
403 GapRects blockSelectionGaps(const RenderBlock* rootBlock, const LayoutPoint& rootBlockPhysicalPosition, const LayoutSize& offsetFromRootBlock, 400 GapRects blockSelectionGaps(const RenderBlock* rootBlock, const LayoutPoint& rootBlockPhysicalPosition, const LayoutSize& offsetFromRootBlock,
404 LayoutUnit& lastLogicalTop, LayoutUnit& lastLogi calLeft, LayoutUnit& lastLogicalRight, const PaintInfo*) const; 401 LayoutUnit& lastLogicalTop, LayoutUnit& lastLogi calLeft, LayoutUnit& lastLogicalRight, const PaintInfo*) const;
405 LayoutRect blockSelectionGap(const RenderBlock* rootBlock, const LayoutPoint & rootBlockPhysicalPosition, const LayoutSize& offsetFromRootBlock, 402 LayoutRect blockSelectionGap(const RenderBlock* rootBlock, const LayoutPoint & rootBlockPhysicalPosition, const LayoutSize& offsetFromRootBlock,
406 LayoutUnit lastLogicalTop, LayoutUnit lastLogic alLeft, LayoutUnit lastLogicalRight, LayoutUnit logicalBottom, const PaintInfo*) const; 403 LayoutUnit lastLogicalTop, LayoutUnit lastLogic alLeft, LayoutUnit lastLogicalRight, LayoutUnit logicalBottom, const PaintInfo*) const;
407 virtual LayoutUnit logicalLeftSelectionOffset(const RenderBlock* rootBlock, LayoutUnit position) const;
408 virtual LayoutUnit logicalRightSelectionOffset(const RenderBlock* rootBlock, LayoutUnit position) const;
409 404
410 // FIXME-BLOCKFLOW: Remove virtualizaion when all callers have moved to Rend erBlockFlow 405 // FIXME-BLOCKFLOW: Remove virtualizaion when all callers have moved to Rend erBlockFlow
411 virtual void clipOutFloatingObjects(const RenderBlock*, const PaintInfo*, co nst LayoutPoint&, const LayoutSize&) const { }; 406 virtual void clipOutFloatingObjects(const RenderBlock*, const PaintInfo*, co nst LayoutPoint&, const LayoutSize&) const { };
412 407
413 virtual void absoluteRects(Vector<IntRect>&, const LayoutPoint& accumulatedO ffset) const OVERRIDE; 408 virtual void absoluteRects(Vector<IntRect>&, const LayoutPoint& accumulatedO ffset) const OVERRIDE;
414 virtual void absoluteQuads(Vector<FloatQuad>&, bool* wasFixed) const OVERRID E; 409 virtual void absoluteQuads(Vector<FloatQuad>&, bool* wasFixed) const OVERRID E;
415 410
416 LayoutUnit desiredColumnWidth() const; 411 LayoutUnit desiredColumnWidth() const;
417 412
418 void paintContinuationOutlines(PaintInfo&, const LayoutPoint&); 413 private:
419
420 virtual LayoutRect localCaretRect(InlineBox*, int caretOffset, LayoutUnit* e xtraWidthToEndOfLine = 0) OVERRIDE FINAL; 414 virtual LayoutRect localCaretRect(InlineBox*, int caretOffset, LayoutUnit* e xtraWidthToEndOfLine = 0) OVERRIDE FINAL;
421 415
422 void adjustPointToColumnContents(LayoutPoint&) const; 416 void adjustPointToColumnContents(LayoutPoint&) const;
423 417
424 void markLinesDirtyInBlockRange(LayoutUnit logicalTop, LayoutUnit logicalBot tom, RootInlineBox* highest = 0); 418 void markLinesDirtyInBlockRange(LayoutUnit logicalTop, LayoutUnit logicalBot tom, RootInlineBox* highest = 0);
425 419
426 Position positionForBox(InlineBox*, bool start = true) const; 420 Position positionForBox(InlineBox*, bool start = true) const;
427 PositionWithAffinity positionForPointWithInlineChildren(const LayoutPoint&); 421 PositionWithAffinity positionForPointWithInlineChildren(const LayoutPoint&);
428 422
429 void calcColumnWidth(); 423 void calcColumnWidth();
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after
504 // FIXME: This is temporary as we move code that accesses block flow 498 // FIXME: This is temporary as we move code that accesses block flow
505 // member variables out of RenderBlock and into RenderBlockFlow. 499 // member variables out of RenderBlock and into RenderBlockFlow.
506 friend class RenderBlockFlow; 500 friend class RenderBlockFlow;
507 }; 501 };
508 502
509 DEFINE_RENDER_OBJECT_TYPE_CASTS(RenderBlock, isRenderBlock()); 503 DEFINE_RENDER_OBJECT_TYPE_CASTS(RenderBlock, isRenderBlock());
510 504
511 } // namespace blink 505 } // namespace blink
512 506
513 #endif // RenderBlock_h 507 #endif // RenderBlock_h
OLDNEW
« no previous file with comments | « Source/core/rendering/InlineBox.cpp ('k') | Source/core/rendering/RenderBlock.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698