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

Unified Diff: third_party/WebKit/Source/core/layout/LayoutBlockFlow.cpp

Issue 2653123002: Changed EClear to an enum class and renamed its members (Closed)
Patch Set: Rebase Created 3 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
Index: third_party/WebKit/Source/core/layout/LayoutBlockFlow.cpp
diff --git a/third_party/WebKit/Source/core/layout/LayoutBlockFlow.cpp b/third_party/WebKit/Source/core/layout/LayoutBlockFlow.cpp
index 359acb0524b8a521a062c2975514686772581dc1..bd5f8ce6ba4b7d0f5f181235f5aac42343f1e8a9 100644
--- a/third_party/WebKit/Source/core/layout/LayoutBlockFlow.cpp
+++ b/third_party/WebKit/Source/core/layout/LayoutBlockFlow.cpp
@@ -2055,7 +2055,7 @@ void LayoutBlockFlow::marginBeforeEstimateForChild(
// require clearance to move past any floats. If that's the case we want to be
// sure we estimate the correct position including margins after any floats
// rather than use 'clearance' later which could give us the wrong position.
- if (grandchildBox->style()->clear() != ClearNone &&
+ if (grandchildBox->style()->clear() != EClear::kNone &&
childBlockFlow->marginBeforeForChild(*grandchildBox) == 0)
return;
@@ -2701,7 +2701,7 @@ LayoutUnit LayoutBlockFlow::getClearDelta(LayoutBox* child,
// We also clear floats if we are too big to sit on the same line as a float
// (and wish to avoid floats by default).
- LayoutUnit result = clear != ClearNone
+ LayoutUnit result = clear != EClear::kNone
? (logicalBottom - logicalTop).clampNegativeToZero()
: LayoutUnit();
if (!result && child->avoidsFloats()) {
@@ -3913,13 +3913,14 @@ void LayoutBlockFlow::addOverhangingFloats(LayoutBlockFlow* child,
}
LayoutUnit LayoutBlockFlow::lowestFloatLogicalBottom(EClear clear) const {
- if (clear == ClearNone || !m_floatingObjects)
+ if (clear == EClear::kNone || !m_floatingObjects)
return LayoutUnit();
- FloatingObject::Type floatType =
- clear == ClearLeft ? FloatingObject::FloatLeft
- : clear == ClearRight ? FloatingObject::FloatRight
- : FloatingObject::FloatLeftRight;
+ FloatingObject::Type floatType = clear == EClear::kLeft
+ ? FloatingObject::FloatLeft
+ : clear == EClear::kRight
+ ? FloatingObject::FloatRight
+ : FloatingObject::FloatLeftRight;
return m_floatingObjects->lowestFloatLogicalBottom(floatType);
}
« no previous file with comments | « third_party/WebKit/Source/core/layout/LayoutBlockFlow.h ('k') | third_party/WebKit/Source/core/layout/LayoutBlockFlowLine.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698