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

Unified Diff: Source/core/rendering/RootInlineBox.cpp

Issue 21430003: Implement interfaces in PaintInfo and make it a class. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@getterPaintInfo01
Patch Set: Fixed Linux compilation (hopefuly Windows too), addressing some reviewer's suggestions. Created 7 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 side-by-side diff with in-line comments
Download patch
Index: Source/core/rendering/RootInlineBox.cpp
diff --git a/Source/core/rendering/RootInlineBox.cpp b/Source/core/rendering/RootInlineBox.cpp
index bd816bbe7fa20d147856a93e4bb6bba5b2b252bd..b308f5c5d3b46b7b8619c6d6d5d7fc94ec9030a1 100644
--- a/Source/core/rendering/RootInlineBox.cpp
+++ b/Source/core/rendering/RootInlineBox.cpp
@@ -169,7 +169,7 @@ float RootInlineBox::placeEllipsisBox(bool ltr, float blockLeftEdge, float block
void RootInlineBox::paintEllipsisBox(PaintInfo& paintInfo, const LayoutPoint& paintOffset, LayoutUnit lineTop, LayoutUnit lineBottom) const
{
if (hasEllipsisBox() && paintInfo.shouldPaintWithinRoot(renderer()) && renderer()->style()->visibility() == VISIBLE
- && paintInfo.phase == PaintPhaseForeground)
+ && paintInfo.getPhase() == PaintPhaseForeground)
ellipsisBox()->paint(paintInfo, paintOffset, lineTop, lineBottom);
}
@@ -427,7 +427,7 @@ LayoutUnit RootInlineBox::lineSnapAdjustment(LayoutUnit delta) const
}
GapRects RootInlineBox::lineSelectionGap(RenderBlock* rootBlock, const LayoutPoint& rootBlockPhysicalPosition, const LayoutSize& offsetFromRootBlock,
- LayoutUnit selTop, LayoutUnit selHeight, const PaintInfo* paintInfo)
+ LayoutUnit selTop, LayoutUnit selHeight, PaintInfo* paintInfo)
{
RenderObject::SelectionState lineState = selectionState();
@@ -463,7 +463,7 @@ GapRects RootInlineBox::lineSelectionGap(RenderBlock* rootBlock, const LayoutPoi
LayoutRect gapRect = rootBlock->logicalRectToPhysicalRect(rootBlockPhysicalPosition, logicalRect);
if (isPreviousBoxSelected && gapRect.width() > 0 && gapRect.height() > 0) {
if (paintInfo && box->parent()->renderer()->style()->visibility() == VISIBLE)
- paintInfo->context->fillRect(gapRect, box->parent()->renderer()->selectionBackgroundColor());
+ paintInfo->getContext()->fillRect(gapRect, box->parent()->renderer()->selectionBackgroundColor());
// VisibleSelection may be non-contiguous, see comment above.
result.uniteCenter(gapRect);
}

Powered by Google App Engine
This is Rietveld 408576698