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

Unified Diff: Source/core/layout/LayoutTextControl.cpp

Issue 926193003: Move rendering/RenderBox to layout/LayoutBox. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 10 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/layout/LayoutTableSection.cpp ('k') | Source/core/layout/LayoutTextControlMultiLine.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/layout/LayoutTextControl.cpp
diff --git a/Source/core/layout/LayoutTextControl.cpp b/Source/core/layout/LayoutTextControl.cpp
index aee7181a6e326c5b437001b2798eb881802cb842..9709aa7ad5ef92b2635dd3fdbc646d68cdb3473e 100644
--- a/Source/core/layout/LayoutTextControl.cpp
+++ b/Source/core/layout/LayoutTextControl.cpp
@@ -107,7 +107,7 @@ int LayoutTextControl::textBlockLogicalWidth() const
LayoutUnit unitWidth = logicalWidth() - borderAndPaddingLogicalWidth();
if (innerEditor->renderer())
- unitWidth -= innerEditor->renderBox()->paddingStart() + innerEditor->renderBox()->paddingEnd();
+ unitWidth -= innerEditor->layoutBox()->paddingStart() + innerEditor->layoutBox()->paddingEnd();
return unitWidth;
}
@@ -129,7 +129,7 @@ void LayoutTextControl::computeLogicalHeight(LayoutUnit logicalHeight, LayoutUni
{
HTMLElement* innerEditor = innerEditorElement();
ASSERT(innerEditor);
- if (RenderBox* innerEditorBox = innerEditor->renderBox()) {
+ if (LayoutBox* innerEditorBox = innerEditor->layoutBox()) {
LayoutUnit nonContentHeight = innerEditorBox->borderAndPaddingHeight() + innerEditorBox->marginHeight();
logicalHeight = computeControlLogicalHeight(innerEditorBox->lineHeight(true, HorizontalLine, PositionOfInteriorLineBoxes), nonContentHeight);
@@ -145,7 +145,7 @@ void LayoutTextControl::computeLogicalHeight(LayoutUnit logicalHeight, LayoutUni
logicalHeight += borderAndPaddingHeight();
}
- RenderBox::computeLogicalHeight(logicalHeight, logicalTop, computedValues);
+ LayoutBox::computeLogicalHeight(logicalHeight, logicalTop, computedValues);
}
void LayoutTextControl::hitInnerEditorElement(HitTestResult& result, const LayoutPoint& pointInContainer, const LayoutPoint& accumulatedOffset)
@@ -155,7 +155,7 @@ void LayoutTextControl::hitInnerEditorElement(HitTestResult& result, const Layou
return;
LayoutPoint adjustedLocation = accumulatedOffset + location();
- LayoutPoint localPoint = pointInContainer - toLayoutSize(adjustedLocation + innerEditor->renderBox()->location());
+ LayoutPoint localPoint = pointInContainer - toLayoutSize(adjustedLocation + innerEditor->layoutBox()->location());
if (hasOverflowClip())
localPoint += scrolledContentOffset();
result.setInnerNode(innerEditor);
@@ -246,8 +246,8 @@ void LayoutTextControl::computeIntrinsicLogicalWidths(LayoutUnit& minLogicalWidt
// Use average character width. Matches IE.
AtomicString family = style()->font().fontDescription().family().family();
maxLogicalWidth = preferredContentLogicalWidth(const_cast<LayoutTextControl*>(this)->getAvgCharWidth(family));
- if (RenderBox* innerEditorRenderBox = innerEditorElement()->renderBox())
- maxLogicalWidth += innerEditorRenderBox->paddingStart() + innerEditorRenderBox->paddingEnd();
+ if (LayoutBox* innerEditorLayoutBox = innerEditorElement()->layoutBox())
+ maxLogicalWidth += innerEditorLayoutBox->paddingStart() + innerEditorLayoutBox->paddingEnd();
if (!style()->logicalWidth().isPercent())
minLogicalWidth = maxLogicalWidth;
}
« no previous file with comments | « Source/core/layout/LayoutTableSection.cpp ('k') | Source/core/layout/LayoutTextControlMultiLine.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698