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

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

Issue 1656743002: Removing more implicit LayoutUnit construction (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix additional test Created 4 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/LayoutInline.cpp
diff --git a/third_party/WebKit/Source/core/layout/LayoutInline.cpp b/third_party/WebKit/Source/core/layout/LayoutInline.cpp
index 14a20e037890730c8c7a8b1f3645d6c0faf07bfb..a4c0baaf6e75d3d87b54f5d1938f6406c77fbb18 100644
--- a/third_party/WebKit/Source/core/layout/LayoutInline.cpp
+++ b/third_party/WebKit/Source/core/layout/LayoutInline.cpp
@@ -709,7 +709,7 @@ LayoutUnit LayoutInline::offsetTop() const
static LayoutUnit computeMargin(const LayoutInline* layoutObject, const Length& margin)
{
if (margin.isFixed())
- return margin.value();
+ return LayoutUnit(margin.value());
if (margin.hasPercent())
return minimumValueForLength(margin, std::max(LayoutUnit(), layoutObject->containingBlock()->availableLogicalWidth()));
return LayoutUnit();
@@ -1426,8 +1426,8 @@ void LayoutInline::addAnnotatedRegions(Vector<AnnotatedRegionValue>& regions)
container = this;
FloatPoint absPos = container->localToAbsolute();
- region.bounds.setX(absPos.x() + region.bounds.x());
- region.bounds.setY(absPos.y() + region.bounds.y());
+ region.bounds.setX(LayoutUnit(absPos.x() + region.bounds.x()));
+ region.bounds.setY(LayoutUnit(absPos.y() + region.bounds.y()));
regions.append(region);
}
« no previous file with comments | « third_party/WebKit/Source/core/layout/LayoutGrid.cpp ('k') | third_party/WebKit/Source/core/layout/LayoutListItem.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698