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

Unified Diff: third_party/WebKit/Source/core/paint/BoxPainter.cpp

Issue 2640143005: Support subpixel layout for borders. (Closed)
Patch Set: 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/paint/BoxPainter.cpp
diff --git a/third_party/WebKit/Source/core/paint/BoxPainter.cpp b/third_party/WebKit/Source/core/paint/BoxPainter.cpp
index e27b590d4d9b9a34d3427d59e66c839501569849..2e8a79b3225219ee154d28640ee59235f694afe4 100644
--- a/third_party/WebKit/Source/core/paint/BoxPainter.cpp
+++ b/third_party/WebKit/Source/core/paint/BoxPainter.cpp
@@ -370,10 +370,10 @@ FloatRoundedRect backgroundRoundedRectAdjustedForBleedAvoidance(
}
}
- FloatRectOutsets insets(-fractionalInset * edges[BSTop].width,
- -fractionalInset * edges[BSRight].width,
- -fractionalInset * edges[BSBottom].width,
- -fractionalInset * edges[BSLeft].width);
+ FloatRectOutsets insets(-fractionalInset * edges[BSTop].width(),
+ -fractionalInset * edges[BSRight].width(),
+ -fractionalInset * edges[BSBottom].width(),
+ -fractionalInset * edges[BSLeft].width());
FloatRoundedRect backgroundRoundedRect = getBackgroundRoundedRect(
obj, borderRect, box, boxSize.width(), boxSize.height(),
@@ -656,8 +656,8 @@ void BoxPainter::paintFillLayer(const LayoutBoxModelObject& obj,
clipToBorder.emplace(obj, paintInfo, rect, border, ApplyToContext);
}
- int bLeft = info.includeLeftEdge ? obj.borderLeft() : 0;
- int bRight = info.includeRightEdge ? obj.borderRight() : 0;
+ LayoutUnit bLeft = info.includeLeftEdge ? obj.borderLeft() : LayoutUnit();
+ LayoutUnit bRight = info.includeRightEdge ? obj.borderRight() : LayoutUnit();
LayoutUnit pLeft = info.includeLeftEdge ? obj.paddingLeft() : LayoutUnit();
LayoutUnit pRight = info.includeRightEdge ? obj.paddingRight() : LayoutUnit();

Powered by Google App Engine
This is Rietveld 408576698