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

Unified Diff: Source/core/rendering/RenderBlock.h

Issue 143323014: *** DO NOT LAND *** Attempt to understand Regions complexity Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/core/rendering/RegionOversetState.h ('k') | Source/core/rendering/RenderBlock.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/rendering/RenderBlock.h
diff --git a/Source/core/rendering/RenderBlock.h b/Source/core/rendering/RenderBlock.h
index 53ca757e7d8614505f11fa057fb4c8f2e7f608ae..228438d9b5b14efd9f1bc2ad402a0a9560f63bf9 100644
--- a/Source/core/rendering/RenderBlock.h
+++ b/Source/core/rendering/RenderBlock.h
@@ -247,39 +247,9 @@ public:
virtual void scrollbarsChanged(bool /*horizontalScrollbarChanged*/, bool /*verticalScrollbarChanged*/) { };
- LayoutUnit logicalLeftOffsetForContent(RenderRegion*) const;
- LayoutUnit logicalRightOffsetForContent(RenderRegion*) const;
- LayoutUnit availableLogicalWidthForContent(RenderRegion* region) const
+ LayoutUnit availableLogicalWidthForContent() const
{
- return max<LayoutUnit>(0, logicalRightOffsetForContent(region) - logicalLeftOffsetForContent(region));
- }
- LayoutUnit startOffsetForContent(RenderRegion* region) const
- {
- return style()->isLeftToRightDirection() ? logicalLeftOffsetForContent(region) : logicalWidth() - logicalRightOffsetForContent(region);
- }
- LayoutUnit endOffsetForContent(RenderRegion* region) const
- {
- return !style()->isLeftToRightDirection() ? logicalLeftOffsetForContent(region) : logicalWidth() - logicalRightOffsetForContent(region);
- }
- LayoutUnit logicalLeftOffsetForContent(LayoutUnit blockOffset) const
- {
- return logicalLeftOffsetForContent(regionAtBlockOffset(blockOffset));
- }
- LayoutUnit logicalRightOffsetForContent(LayoutUnit blockOffset) const
- {
- return logicalRightOffsetForContent(regionAtBlockOffset(blockOffset));
- }
- LayoutUnit availableLogicalWidthForContent(LayoutUnit blockOffset) const
- {
- return availableLogicalWidthForContent(regionAtBlockOffset(blockOffset));
- }
- LayoutUnit startOffsetForContent(LayoutUnit blockOffset) const
- {
- return startOffsetForContent(regionAtBlockOffset(blockOffset));
- }
- LayoutUnit endOffsetForContent(LayoutUnit blockOffset) const
- {
- return endOffsetForContent(regionAtBlockOffset(blockOffset));
+ return max<LayoutUnit>(0, logicalRightOffsetForContent() - logicalLeftOffsetForContent());
}
LayoutUnit logicalLeftOffsetForContent() const { return isHorizontalWritingMode() ? borderLeft() + paddingLeft() : borderTop() + paddingTop(); }
LayoutUnit logicalRightOffsetForContent() const { return logicalLeftOffsetForContent() + availableLogicalWidth(); }
@@ -385,9 +355,6 @@ protected:
virtual void computeSelfHitTestRects(Vector<LayoutRect>&, const LayoutPoint& layerOffset) const OVERRIDE;
- bool updateRegionsAndShapesLogicalSize(RenderFlowThread*);
- void computeRegionRangeForBlock(RenderFlowThread*);
-
void updateBlockChildDirtyBitsBeforeLayout(bool relayoutChildren, RenderBox*);
virtual void checkForPaginationLogicalHeightChange(LayoutUnit& pageLogicalHeight, bool& pageLogicalHeightChanged, bool& hasSpecifiedPageLogicalHeight);
@@ -396,7 +363,6 @@ protected:
private:
void computeShapeSize();
- void updateRegionsAndShapesAfterChildLayout(RenderFlowThread*, bool);
void updateShapeInsideInfoAfterStyleChange(const ShapeValue*, const ShapeValue* oldShape);
void relayoutShapeDescendantIfMoved(RenderBlock* child, LayoutSize offset);
@@ -555,8 +521,7 @@ protected:
void updateMinimumPageHeight(LayoutUnit offset, LayoutUnit minHeight);
LayoutUnit adjustForUnsplittableChild(RenderBox* child, LayoutUnit logicalOffset, bool includeMargins = false); // If the child is unsplittable and can't fit on the current page, return the top of the next page/column.
- void adjustLinePositionForPagination(RootInlineBox*, LayoutUnit& deltaOffset, RenderFlowThread*); // Computes a deltaOffset value that put a line at the top of the next page if it doesn't fit on the current page.
- void updateRegionForLine(RootInlineBox*) const;
+ void adjustLinePositionForPagination(RootInlineBox*, LayoutUnit& deltaOffset); // Computes a deltaOffset value that put a line at the top of the next page if it doesn't fit on the current page.
// Adjust from painting offsets to the local coords of this renderer
void offsetForContents(LayoutPoint&) const;
@@ -564,9 +529,7 @@ protected:
// This function is called to test a line box that has moved in the block direction to see if it has ended up in a new
// region/page/column that has a different available line width than the old one. Used to know when you have to dirty a
// line, i.e., that it can't be re-used.
- bool lineWidthForPaginatedLineChanged(RootInlineBox*, LayoutUnit lineDelta, RenderFlowThread*) const;
-
- bool logicalWidthChangedInRegions(RenderFlowThread*) const;
+ bool lineWidthForPaginatedLineChanged(RootInlineBox*, LayoutUnit lineDelta) const;
virtual bool requiresColumns(int desiredColumnCount) const;
@@ -576,8 +539,6 @@ protected:
public:
virtual LayoutUnit offsetFromLogicalTopOfFirstPage() const OVERRIDE FINAL;
- RenderRegion* regionAtBlockOffset(LayoutUnit) const;
- RenderRegion* clampToStartAndEndRegions(RenderRegion*) const;
public:
@@ -631,7 +592,7 @@ inline bool RenderBlock::allowsShapeInsideInfoSharing(const RenderBlock* other)
{
if (!other)
return false;
- for (const RenderBlock* current = this; current && current != other && !current->isRenderFlowThread(); current = current->containingBlock()) {
+ for (const RenderBlock* current = this; current && current != other; current = current->containingBlock()) {
if (current->isInline() || current->isFloating())
return false;
if (current->parent() != current->containingBlock())
« no previous file with comments | « Source/core/rendering/RegionOversetState.h ('k') | Source/core/rendering/RenderBlock.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698